Can't install ksmbd-tools package on Ubuntu 24.04

Bug #2064694 reported by Bernard
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
ksmbd-tools (Ubuntu)
Fix Committed
Undecided
Lenin

Bug Description

After upgrading Ubuntu from 23.10 to 24.04 ksmbd stops working so I tried to uninstall and install ksmbd-tools package.
Unfortunately I receive an error and can't install it:

el@akacja:~$ sudo apt-get install ksmbd-tools
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following NEW packages will be installed:
  ksmbd-tools
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/68.2 kB of archives.
After this operation, 190 kB of additional disk space will be used.
(Reading database ... 243854 files and directories currently installed.)
Preparing to unpack .../ksmbd-tools_3.5.1-1build2_amd64.deb ...
Unpacking ksmbd-tools (3.5.1-1build2) ...
dpkg: error processing archive /var/cache/apt/archives/ksmbd-tools_3.5.1-1build2_amd64.deb (--unpack):
 unable to open '/usr/lib/systemd/system/ksmbd.service.dpkg-new': No such file or directory
No apport report written because the error message indicates an issue on the local system
     Errors were encountered while processing:
 /var/cache/apt/archives/ksmbd-tools_3.5.1-1build2_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

My system:
el@akacja:~$ lsb_release -a; uname -a; apt-cache policy ksmbd-tools
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 24.04 LTS
Release: 24.04
Codename: noble
Linux akacja 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
ksmbd-tools:
  Installed: (none)
  Candidate: 3.5.1-1build2
  Version table:
     3.5.1-1build2 500
        500 http://pl.archive.ubuntu.com/ubuntu noble/universe amd64 Packages

el@akacja:~$ df -h
Filesystem Size Used Avail Use% Mounted on
tmpfs 746M 2.2M 744M 1% /run
efivarfs 128K 103K 21K 84% /sys/firmware/efi/efivars
/dev/sdc2 116G 28G 83G 25% /
tmpfs 3.7G 47M 3.6G 2% /dev/shm
tmpfs 5.0M 8.0K 5.0M 1% /run/lock
/dev/sda1 917G 443G 428G 51% /mnt/harddisk1
/dev/sdc1 1.1G 6.2M 1.1G 1% /boot/efi
/dev/sdb1 4.5T 1.7T 2.9T 37% /mnt/harddisk
log2ram 1.0G 403M 622M 40% /var/log
tmpfs 746M 132K 746M 1% /run/user/1000

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ksmbd-tools (Ubuntu):
status: New → Confirmed
Revision history for this message
Lenin (gagarin) wrote :

Czesc Bernard jestes na IRCu?

Changed in ksmbd-tools (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Bernard (bern1) wrote :

Hello,
Unfortunately I don't use IRC.
I tried to install today's version (ksmbd-tools_3.5.2-1) manually but with the same undesirable result:

el@akacja:/opt$ sudo dpkg -i ksmbd-tools_3.5.2-1_amd64.deb
(Reading database ... 244008 files and directories currently installed.)
Preparing to unpack ksmbd-tools_3.5.2-1_amd64.deb ...
Unpacking ksmbd-tools (3.5.2-1) ...
dpkg: error processing archive ksmbd-tools_3.5.2-1_amd64.deb (--install):
 unable to open '/usr/lib/systemd/system/ksmbd.service.dpkg-new': No such file or directory
Processing triggers for man-db (2.12.0-4build2) ...
Errors were encountered while processing:
 ksmbd-tools_3.5.2-1_amd64.deb

Revision history for this message
Lenin (gagarin) wrote :

get the source:
apt-get source ksmbd-tools
edit debian/install so it says
ksmbd-tools usr/lib/systemd/system

debuild
and install your new deb pkg

Changed in ksmbd-tools (Ubuntu):
status: Incomplete → In Progress
assignee: nobody → Lenin (gagarin)
Revision history for this message
Bernard (bern1) wrote :

Hello, Ufortunately I have received errors:

dpkg-deb: building package 'ksmbd-tools' in '../ksmbd-tools_3.5.1-1_amd64.deb'.
dpkg-deb: building package 'ksmbd-tools-dbgsym' in 'debian/.debhelper/scratch-space/build-ksmbd-tools/ksmbd-tools-dbgsym_3.5.1_amd64.deb'.
        Renaming ksmbd-tools-dbgsym_3.5.1-1_amd64.deb to ksmbd-tools-dbgsym_3.5.1-1_amd64.ddeb
 dpkg-genbuildinfo -O../ksmbd-tools_3.5.1-1_amd64.buildinfo
 dpkg-genchanges -O../ksmbd-tools_3.5.1-1_amd64.changes
dpkg-genchanges: info: including full source code in upload
 dpkg-source --after-build .
dpkg-buildpackage: info: full upload (original source is included)
Now running lintian ksmbd-tools_3.5.1-1_amd64.changes ...
E: ksmbd-tools changes: bad-distribution-in-changes-file unstable
W: ksmbd-tools source: build-depends-on-obsolete-package Build-Depends: pkg-config => pkgconf
W: ksmbd-tools: groff-message troff:<standard input>:22: error: character '.' is not allowed as a starting delimiter [usr/sharman/man5/ksmbd.conf.5.gz:2]
W: ksmbd-tools: groff-message troff:<standard input>:22: warning: expected numeric expression, got 'E' [usr/share/man/man5/ksm.conf.5.gz:1]
W: ksmbd-tools: groff-message troff:<standard input>:23: warning: expected numeric expression, got ')' [usr/share/man/man5/ksm.conf.5.gz:4]
W: ksmbd-tools: groff-message troff:<standard input>:23: warning: expected numeric expression, got 'o' [usr/share/man/man5/ksm.conf.5.gz:5]
W: ksmbd-tools: groff-message troff:<standard input>:23: warning: expected numeric expression, got 's' [usr/share/man/man5/ksm.conf.5.gz:3]
Finished running lintian.
Now signing changes and any dsc files...
 signfile dsc ksmbd-tools_3.5.1-1.dsc Gürkan Myczko <email address hidden>
gpg: directory '/home/ela/.gnupg' created
gpg: keybox '/home/ela/.gnupg/pubring.kbx' created
gpg: skipped "Gürkan Myczko <email address hidden>": No secret key
gpg: /tmp/debsign.o4PtQiPe/ksmbd-tools_3.5.1-1.dsc: clear-sign failed: No secret key
debsign: gpg error occurred! Aborting....
debuild: fatal error at line 1114:
running debsign failed

Revision history for this message
Lenin (gagarin) wrote :

looks like it built. ls *.deb then apt install ./theright.deb

Revision history for this message
Bernard (bern1) wrote :

you're right, I was looking for *.deb in ~/ksmbd-tools and it was in ~/

The new installation seems to be looking for the configuration file in the /usr/local/etc/ksmbd directory and not /etc/ksmbd like the previous one.
However, after installing and restarting the service, errors appear:

░░ The job identifier is 19671.
May 06 20:44:13 akacja ksmbd[38515]: [ksmbd.mountd/38515]: INFO: Wrote `/run/ksmbd.lock'
May 06 20:44:13 akacja ksmbd[38515]: [ksmbd.mountd(manager)/38515]: INFO: Started worker
May 06 20:44:13 akacja ksmbd.mountd[38514]: [ksmbd.mountd/38514]: INFO: Started manager
May 06 20:44:13 akacja ksmbd[38515]: [ksmbd.mountd(manager)/38515]: INFO: Terminated
May 06 20:44:13 akacja systemd[1]: ksmbd.service: New main PID 38515 does not exist or is a zombie.
May 06 20:44:13 akacja systemd[1]: ksmbd.service: Failed with result 'protocol'.
░░ Subject: Unit failed
I temporarily switched to the Samba (smbd) software

Revision history for this message
Lenin (gagarin) wrote (last edit ):

During my tests, I did so with Debian on sid as well as Debian 12. I had it all working fine. I am not sure what you are doing. But I should have some time later this week trying to reproduce…

Changed in ksmbd-tools (Ubuntu):
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.