Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: change to use GitHub actions #86

Merged
merged 4 commits into from
Jul 4, 2024
Merged

Conversation

FrankYang0529
Copy link
Contributor

Which issue(s) this PR fixes:

longhorn/longhorn#8039

What this PR does / why we need it:

Special notes for your reviewer:

Additional documentation or context

@FrankYang0529
Copy link
Contributor Author

Hi @derekbit, may you help to check the error test case? It looks like we didn't have CI for this repository.

@derekbit
Copy link
Member

iscsi_test.go:81:
    c.Assert(err, IsNil)
... value *errors.withStack = failed to execute: /usr/bin/nsenter [nsenter iscsiadm --version], output , stderr nsenter: failed to execute iscsiadm: No such file or directory
: exit status 1 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm --version], output , stderr nsenter: failed to execute iscsiadm: No such file or directory\n: exit status 1")

iSCSI service is not installed.
Check the installation in the doc on different OSes.

@derekbit
Copy link
Member

Found found the Dockerfile.dapper relise ubuntu:16.04 base image. @FrankYang0529 Can you help create a ticket for migrating it to BCI image? Thank you.

@FrankYang0529
Copy link
Contributor Author

iscsi_test.go:81:
    c.Assert(err, IsNil)
... value *errors.withStack = failed to execute: /usr/bin/nsenter [nsenter iscsiadm --version], output , stderr nsenter: failed to execute iscsiadm: No such file or directory
: exit status 1 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm --version], output , stderr nsenter: failed to execute iscsiadm: No such file or directory\n: exit status 1")

iSCSI service is not installed. Check the installation in the doc on different OSes.

Thank you. It looks like the error message change after I add open-iscsi.

@derekbit
Copy link
Member

value *errors.withStack = failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.2], output , stderr iscsiadm: c

kernel module is missing. Try modprobe iscsi_tcp.

Copy link
Member

@innobead innobead left a comment

Choose a reason for hiding this comment

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

Need to fix the failed PR check.

Running tests
modprobe: FATAL: Module iscsi_tcp not found in directory /lib/modules/6.5.0-1018-azure
Failed to load iscsi_tcp module
time="2024-04-30T06:37:02Z" level=fatal msg="exit status 1"
make: *** [Makefile:11: ci] Error 1

Dockerfile.dapper Show resolved Hide resolved
Dockerfile.dapper Outdated Show resolved Hide resolved
@derekbit
Copy link
Member

@FrankYang0529 Is it ready to review?

@FrankYang0529
Copy link
Contributor Author

@FrankYang0529 Is it ready to review?

This one is like go-spdk-helper and longhorn-spdk-engine. It need system modules like iSCSI daemon. Do you know how to start it in container? The testing error message is:

: exit status 12 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.2], output , stderr Running in chroot, ignoring command 'start'\niscsiadm: can not connect to iSCSI daemon (111)!\niscsiadm: Could not scan /sys/class/iscsi_transport.\nlibkmod: kmod_module_insert_module: could not find module by name='iscsi_tcp'\niscsiadm: Could not insert module tcp. Kmod error -2\niscsiadm: iSCSI driver tcp is not loaded. Load the module then retry the command.\niscsiadm: Could not perform SendTargets discovery: iSCSI driver not found. Please make sure it is loaded, and retry the operation\n: exit status 12")

@derekbit
Copy link
Member

@FrankYang0529 Is it ready to review?

This one is like go-spdk-helper and longhorn-spdk-engine. It need system modules like iSCSI daemon. Do you know how to start it in container? The testing error message is:

: exit status 12 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.2], output , stderr Running in chroot, ignoring command 'start'\niscsiadm: can not connect to iSCSI daemon (111)!\niscsiadm: Could not scan /sys/class/iscsi_transport.\nlibkmod: kmod_module_insert_module: could not find module by name='iscsi_tcp'\niscsiadm: Could not insert module tcp. Kmod error -2\niscsiadm: iSCSI driver tcp is not loaded. Load the module then retry the command.\niscsiadm: Could not perform SendTargets discovery: iSCSI driver not found. Please make sure it is loaded, and retry the operation\n: exit status 12")

It seems kernel module is not found.
Can you try modprobe iscsi_tcp?

@FrankYang0529
Copy link
Contributor Author

@FrankYang0529 Is it ready to review?

This one is like go-spdk-helper and longhorn-spdk-engine. It need system modules like iSCSI daemon. Do you know how to start it in container? The testing error message is:

: exit status 12 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.2], output , stderr Running in chroot, ignoring command 'start'\niscsiadm: can not connect to iSCSI daemon (111)!\niscsiadm: Could not scan /sys/class/iscsi_transport.\nlibkmod: kmod_module_insert_module: could not find module by name='iscsi_tcp'\niscsiadm: Could not insert module tcp. Kmod error -2\niscsiadm: iSCSI driver tcp is not loaded. Load the module then retry the command.\niscsiadm: Could not perform SendTargets discovery: iSCSI driver not found. Please make sure it is loaded, and retry the operation\n: exit status 12")

It seems kernel module is not found. Can you try modprobe iscsi_tcp?

We can't use modprobe command in container. It's like issue in longhorn-spdk-engine and go-spdk-helper.

@derekbit
Copy link
Member

@FrankYang0529 Is it ready to review?

This one is like go-spdk-helper and longhorn-spdk-engine. It need system modules like iSCSI daemon. Do you know how to start it in container? The testing error message is:

: exit status 12 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.2], output , stderr Running in chroot, ignoring command 'start'\niscsiadm: can not connect to iSCSI daemon (111)!\niscsiadm: Could not scan /sys/class/iscsi_transport.\nlibkmod: kmod_module_insert_module: could not find module by name='iscsi_tcp'\niscsiadm: Could not insert module tcp. Kmod error -2\niscsiadm: iSCSI driver tcp is not loaded. Load the module then retry the command.\niscsiadm: Could not perform SendTargets discovery: iSCSI driver not found. Please make sure it is loaded, and retry the operation\n: exit status 12")

It seems kernel module is not found. Can you try modprobe iscsi_tcp?

We can't use modprobe command in container. It's like issue in longhorn-spdk-engine and go-spdk-helper.

You can modprobe it in the hostname space instead.

@derekbit
Copy link
Member

derekbit commented Jul 3, 2024

Hi @derekbit, may you help to check the error test case? It looks like we didn't have CI for this repository.

You are right. I just realized we never run CI here.

FrankYang0529 and others added 4 commits July 3, 2024 16:42
Longhorn 8039

Signed-off-by: Derek Su <[email protected]>
Longhorn 8039

Signed-off-by: Derek Su <[email protected]>
Longhorn 8039

Signed-off-by: Derek Su <[email protected]>
@derekbit
Copy link
Member

derekbit commented Jul 3, 2024

@FrankYang0529 @innobead
We never ran the CI test.
I tried to fix the error but with no luck for now

 exit status 20 ("failed to execute: /usr/bin/nsenter [nsenter iscsiadm -m discovery -t sendtargets -p 172.17.0.3], 
output , stderr System has not been booted with systemd as init system (PID 1). Can't operate.\nFailed to connect to bus:
 Host is down\niscsiadm: can not connect to iSCSI daemon (111)!\nSystem has not been booted with systemd as init system (PID 1). Can't operate.\n
 Failed to connect to bus: Host is down\niscsiadm: can not connect to iSCSI daemon (111)!\niscsiadm: Cannot perform discovery. Initiatorname required.\n
 iscsiadm: Could not perform SendTargets discovery: could not connect to iscsid\n: exit status 20")

I think we can disable CI test as before and fix it later. WDYT?

@FrankYang0529
Copy link
Contributor Author

I think we can disable CI test as before and fix it later. WDYT?

Agree. The go-iscsi-helper works well. We just need to find a way to test it in the future. Thank you.

@derekbit derekbit merged commit b96e547 into longhorn:master Jul 4, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants