samba: nmbd no longer starts automatically after gutsy upgrade

Bug #177802 reported by phirestalker
4
Affects Status Importance Assigned to Milestone
samba (Ubuntu)
New
Undecided
Unassigned

Bug Description

I have my printer connected to the ubuntu machine, and it is shared through ipp and samba, I noticed an issue when I was unable to print from a windows machine, I looked through settings I found that I was also unable to access shares on the ubuntu machine, so I looked and found that the nmbd process was not started, I could not start it manually as it wouldn't fix the problem, I guess I didn't use the right command line. If however I go to the new samba control applet and clicked server settings and then ok it would start the nmbd process and things work fine.

Revision history for this message
jtholmes (jtholmes) wrote :

thank you for your report

can you detail the command you tried to use to start nmbd/smbd?

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote : Re: [Bug 177802] Re: samba: nmbd no longer starts automatically after gutsy upgrade

I have tried nmbd as root and also nmbd -D even though the man page says
-D is default operation, and one time it started and then it died
without crashing as far as I know (no crash file in /var/crash) and
another time it was running but didn't fix the problem, I imagine the
time it died was a fluke as it only happened once.

On Sat, 2008-01-05 at 00:06 +0000, jtholmes wrote:
> thank you for your report
>
> can you detail the command you tried to use to start nmbd/smbd?
>
> ** Changed in: samba (Ubuntu)
> Sourcepackagename: None => samba
>

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

I found these lines in /var/log/daemon.log

Jan 9 21:57:07 localhost nmbd[6073]: [2008/01/09 21:57:07, 1] param/loadparm.c:lp_do_parameter(3517)
Jan 9 21:57:07 localhost nmbd[6073]: WARNING: The "printer admin" option is deprecated
Jan 9 21:57:07 localhost nmbd[6094]: [2008/01/09 21:57:07, 0] nmbd/nmbd_subnetdb.c:create_subnets(245)
Jan 9 21:57:07 localhost nmbd[6094]: create_subnets: unable to create any subnet from given interfaces. nmbd is terminating
Jan 9 21:57:07 localhost nmbd[6094]: [2008/01/09 21:57:07, 0] nmbd/nmbd.c:main(771)
Jan 9 21:57:07 localhost nmbd[6094]: ERROR: Failed when creating subnet lists. Exiting.

I noticed that after these lines the network manager is still bringing up the eth0 interface, perhaps smbd is now being started too early in the boot process??? hope this helps

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

samba is at S20 and dhcdbd is S24 so it seems as though samba is indeed trying to use a network that is not yet configured.

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

ok I think if I change one number in postinst in the deb file it will probably start without problem I will try editing it and then reinstalling.

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

alright that didn't work, it looks like dhcdbd starts too late in the game still even thought it starts at S24 which is before networking, networkmanager tries at least 25 times to load eth0 before dhcdbd starts allowing networkmanager to finish. I'm not sure what to try next, instead of messing with orders of other programs I think I will just move samba even later, although if these other programs were cleaned up somehow and it didn't have to try 25 times the system may boot a little faster too?? If anyone has any suggestions let me know

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

I moved samba to friggin S70 and now networkmanager gets it's address EVEN LATER?!?!?! what the hell is going on? I'm going to reboot one more time with S70 as it may have been a fluke, better yet I'll shut down for a few seconds to let the networking equipment realize I'm gone before booting back up.

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

ok fixed and working with S92 this seems like an ugly workaround for now, as the problem is really caused by the interaction of dhcdbd and networkmanager. As I mentioned before dhcdbd starts S24 which should be WAY before S50 where I moved samba to originally, I did not see any errors which would explain this odd behavior in daemon.log but I will upload it anyway. Let me know if I need to file a bug with networkmanager or dhcdbd instead. Thanks

Revision history for this message
phirestalker (firestalker1-deactivatedaccount) wrote :

UPDATE: the S92 fix does not work all the time there is seriously something else wrong here for the network to STILL not be up by S92.

Revision history for this message
Soren Hansen (soren) wrote :

On Tue, Jan 22, 2008 at 11:43:49PM -0000, phirestalker wrote:
> UPDATE: the S92 fix does not work all the time there is seriously
> something else wrong here for the network to STILL not be up by S92.

The problem is that the network doesn't get configured until you login.
That's the magic of network manager. Since nmbd doesn't find a network,
it exits. The fix is to let nmbd stay alive even though there is no
network to serve requests for. There is already a bug about this.
Marking as duplicate.

 duplicate 180493

--
Soren Hansen
Ubuntu Server Team
http://www.ubuntu.com/

Revision history for this message
CheShA (8-launchpad-net-chesha-com) wrote :

an effective workaround is to have a small script at /etc/network/if-up.d/start-samba.sh that simply contains the lines:

#!/bin/bash
/etc/init.d/samba restart

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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