Skip to content

[openssh] Update openssh make file, add missing dependency to libnl.#12327

Merged
liuh-80 merged 2 commits intosonic-net:masterfrom
liuh-80:dev/liuh/fix-openssh-dep
Oct 24, 2022
Merged

[openssh] Update openssh make file, add missing dependency to libnl.#12327
liuh-80 merged 2 commits intosonic-net:masterfrom
liuh-80:dev/liuh/fix-openssh-dep

Conversation

@liuh-80
Copy link
Contributor

@liuh-80 liuh-80 commented Oct 10, 2022

Update openssh make file, add missing dependency to libnl.

Why I did it

Openssh indirectly depends on libnl.
Another PR #12447 need add new patch to openssh, after adding new patch to openssh, PR build failed with libnl missing error.

How I did it

Update openssh make file, add missing dependency to libnl.

How to verify it

Pass all test case

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205

Description for the changelog

Update openssh make file, add missing dependency to libnl.

Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU.

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@liuh-80 liuh-80 changed the title [openssh] Update openssh make file, add missing depency to libnl. [openssh] Update openssh make file, add missing dependency to libnl. Oct 10, 2022
@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 10, 2022

Close, now sonic using fips version.

@liuh-80 liuh-80 closed this Oct 10, 2022
@liuh-80 liuh-80 reopened this Oct 19, 2022
@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

Here is openssh build error:

2022-10-19T09:45:14.5743687Z The following packages have unmet dependencies:
2022-10-19T09:45:14.5744821Z libibverbs1 : Depends: libnl-route-3-200 (>= 3.2.7) but it is not going to be installed
2022-10-19T09:45:14.5745774Z E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
2022-10-19T09:45:14.5747200Z make[1]: *** [Makefile:9: /sonic/target/debs/bullseye/openssh-server_8.4p1-5+deb11u1_amd64.deb] Error 100

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

Build failed with this error, seems a agent pool issue:
E: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 58398 (dpkg)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
make[1]: *** [Makefile:9: /sonic/target/debs/bullseye/openssh-server_8.4p1-5+deb11u1_amd64.deb] Error 100

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 20, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 21, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 21, 2022

/azp run Azure.sonic-buildimage

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@liuh-80 liuh-80 marked this pull request as ready for review October 21, 2022 07:13

OPENSSH_SERVER = openssh-server_$(OPENSSH_VERSION)_$(CONFIGURED_ARCH).deb
$(OPENSSH_SERVER)_SRC_PATH = $(SRC_PATH)/openssh
$(OPENSSH_SERVER)_DEPENDS += $(LIBNL3_DEV) $(LIBNL_ROUTE3_DEV)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LIBNL_ROUTE3_DEV

Seem this fix is a valid fix, and has no relationship with the other PR 12447 .

I am worried about why this bug is not exposed before? Could you check previous build log and possible find a build bug?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xumia please be aware of this issue.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LIBNL_ROUTE3_DEV

Seem this fix is a valid fix, and has no relationship with the other PR 12447 .

I am worried about why this bug is not exposed before? Could you check previous build log and possible find a build bug?

I checked the build log and not found build issue caused by this.
When build on local devbox or run a full build, in most case we build everything from source code, so the libnl will be build and install before openssh build.

Here is how this issue happen:
When build on azure pipeline, we are using cache, so when change openssh code, the libnl will not build because there is no code change, also libnl will not be installed from cache. then openssh will build break because missing package.

@liuh-80 liuh-80 merged commit fff6808 into sonic-net:master Oct 24, 2022
@liuh-80
Copy link
Contributor Author

liuh-80 commented Oct 26, 2022

Request this for 202205 branch, later there will be another PR depends on this also will request for 202205 branch:

#12447

yxieca pushed a commit that referenced this pull request Oct 27, 2022
…12327)

Update openssh make file, add missing dependency to libnl.

#### Why I did it
Openssh indirectly depends on libnl.
Another PR #12447 need add new patch to openssh, after adding new patch to openssh, PR build failed with libnl missing error.

#### How I did it
Update openssh make file, add missing dependency to libnl.

#### How to verify it
Pass all test case

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106
- [ ] 202111
- [ ] 202205

#### Description for the changelog
Update openssh make file, add missing dependency to libnl.

#### Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU.

#### Link to config_db schema for YANG module changes
<!--
Provide a link to config_db schema for the table for which YANG model
is defined
Link should point to correct section on https://github.com/Azure/sonic-buildimage/blob/master/src/sonic-yang-models/doc/Configuration.md
-->

#### A picture of a cute animal (not mandatory but encouraged)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants