/srv/irclogs.ubuntu.com/2021/07/24/#ubuntu-server.txt

SebastianGrabowsHi! I'm having some problems to set up an iscsi target on Ubuntu Server 20.04. I've set up the target using targetcli and saved the config. The configuration gets restored after reboot, so everything looks fine there. But although the target is configured to listen on 0.0.0.0:3260 it seems that the server is not listening on port 3260 (at least according to `lsof -i`). Is there something special (like e.g. some service) that has15:07
SebastianGrabowsto be enabled here?15:07
TJ-SebastianGrabows: is this something you've read? https://ubuntu.com/server/docs/service-iscsi15:16
SebastianGrabows<TJ- "Sebastian Grabowski: is this som"> Yes, it unfortunately describes only the initiator setup. I'm stuck at configuring the target.15:17
TJ-oh!15:18
TJ-SebastianGrabows: can the debian wiki links help? https://wiki.debian.org/SAN/iSCSI15:20
SebastianGrabows<TJ- "Sebastian Grabowski: can the deb"> Not really. My steps were actually similar to the workflow described there: https://wiki.debian.org/SAN/iSCSI/LIO . The targetcli config looks like this right now: https://paste.ubuntu.com/p/NjjM2dsjxK/ The problem is that the portal isn't listening: https://paste.ubuntu.com/p/73nNy9fFMH/15:28
TJ-SebastianGrabows: is the service actually running?15:39
TJ-SebastianGrabows: something like "systemctl status iscsitarget"15:40
SebastianGrabows<TJ- "Sebastian Grabowski: something l"> These are all services with scsi or target in their names and all are enabled: https://paste.ubuntu.com/p/tG7nHVpvXQ/15:48
TJ-SebastianGrabows: are they running now, though?15:51
=== JanC_ is now known as JanC
SebastianGrabowsThey all run, except of open-iscsi but that shouldn't be a problem because as far as I understand it is used only by initiators.16:03
TJ-I'm stumped then; network tooling seems to show the process isn't listening so I'd assume it isn't running, so that would be where I'd focus - what is the process name, which service file starts it, what is its status16:06
SebastianGrabowsI think that maybe there shouldn't be a systemd service since LIO is handled by the kernel: https://wiki.archlinux.org/title/ISCSI/LIO16:11
SebastianGrabowsThe necessary modules are currently loaded.16:11
TJ-can you use another system to probe the expected port?16:14
SebastianGrabowsOh! Probing with nmap shows that the port is actually open! Funny thing that `lsof -i` says otherwise. Sorry for wasting your time on this. Thanks!16:22
TJ-SebastianGrabows: grrr @ kernel !16:24
TJ-SebastianGrabows: does 'ss' report the port if lsof doesn't? "sudo ss -tnlp sport = 3260"16:24
SebastianGrabows<TJ- "Sebastian Grabowski: does 'ss' r"> Yup: https://paste.ubuntu.com/p/Sbg3MvkPG8/16:27
SebastianGrabowsI think I found out why lsof didn't show the port. It seems that lsof looks in /proc/*/fd for sockets. Thus ports opened by the kernel may not show up there. Good to know!16:40
TJ-SebastianGrabows: yeah, horrible when you get caught out by things like that16:46
=== Woet_ is now known as Woet

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!