Skip to contentSkip to conversation

Bug#728876: qemu: smbd forked by qemu uses global directory /var/run/samba/ncalrpc

Qemu-devel Michael Tokarev 1 participant 3 messages Nov 28, 2013 – Apr 7, 2014 1 message not in the archive Networking

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 20131106130127.31489.30934.reportbug@localhost

#1 lore raw

Jan, there's one more samba-related fix for slirp, also from Michael Büsch.

Add my

if needed.

Thanks,

/mjt

Quoted 15 lines · Michael Büsch

Package: qemu
Version: 1.6.0+dfsg-2
Severity: normal
Tags: patch

The smbd forked by qemu still uses the default ncalrpc directory in /var/run/samba. This may lead to problems, if the directory does not exist (for example if /var/run is a tmpfs and the host smbd was not started).

This leads to the following error message from samba
and an unworkable smbd:
Failed to create pipe directory /var/run/samba/ncalrpc - No such file
or directory

Quoted 5 lines

The attached patch fixes this by pointing smbd to /tmp/qemu-smb.%d.%d/ncalrpc as ncalrpc directory.
Smbd will create the actual ncalrpc subdirectory on its own.

Using a private directory also avoids possible clashes with the system-smbd.

From: Michael Buesch <[email protected]>
Subject: [PATCH] slirp/smb: Move ncalrpc directory to tmp

The smbd forked by qemu still uses the default ncalrpc directory in /var/run/samba. This may lead to problems, if /var/run/samba does not exist (for example if /var/run is a tmpfs and the host smbd was not started).

This leads to the following error message from samba
and an unworkable smbd:
Failed to create pipe directory /var/run/samba/ncalrpc - No such file or directory

Fix this by pointing smbd to /tmp/qemu-smb.%d.%d/ncalrpc as ncalrpc directory. Smbd will create the actual ncalrpc subdirectory on its own.

---

net/slirp.c +2 -0
Index: qemu-1.6.0+dfsg/net/slirp.c
===================================================================
@@ -527,6 +527,7 @@ static int slirp_smb(SlirpState* s, cons
             "pid directory=%s\n"
             "lock directory=%s\n"
             "state directory=%s\n"
+            "ncalrpc dir=%s/ncalrpc\n"
             "log file=%s/log.smbd\n"
             "smb passwd file=%s/smbpasswd\n"
             "security = user\n"
@@ -539,6 +540,7 @@ static int slirp_smb(SlirpState* s, cons
             s->smb_dir,
             s->smb_dir,
             s->smb_dir,
+            s->smb_dir,
             s->smb_dir,
             s->smb_dir,
             s->smb_dir,
#2 lore raw

Ping? Again, more than 2 months passed since initial submission.

Thanks,

/mjt

Quoted 34 lines · Michael Tokarev

Jan, there's one more samba-related fix for slirp, also from Michael Büsch.

Add my

if needed.

Thanks,

/mjt

Quoted 20 lines · Michael Büsch

Package: qemu
Version: 1.6.0+dfsg-2
Severity: normal
Tags: patch

The smbd forked by qemu still uses the default ncalrpc directory in /var/run/samba. This may lead to problems, if the directory does not exist (for example if /var/run is a tmpfs and the host smbd was not started).

This leads to the following error message from samba
and an unworkable smbd:
Failed to create pipe directory /var/run/samba/ncalrpc - No such file
or directory

The attached patch fixes this by pointing smbd to /tmp/qemu-smb.%d.%d/ncalrpc as ncalrpc directory.
Smbd will create the actual ncalrpc subdirectory on its own.

Using a private directory also avoids possible clashes with the system-smbd.

#3 lore raw
Quoted 1 line · Michael Tokarev

Ping? Again, more than 2 months passed since initial submission.

Ping#2 ?
Should it go to -trivial maybe?

Thanks,

/mjt

Quoted 38 lines
Quoted 34 lines · Michael Tokarev

Jan, there's one more samba-related fix for slirp, also from Michael Büsch.

Add my

if needed.

Thanks,

/mjt

Quoted 20 lines · Michael Büsch

Package: qemu
Version: 1.6.0+dfsg-2
Severity: normal
Tags: patch

The smbd forked by qemu still uses the default ncalrpc directory in /var/run/samba. This may lead to problems, if the directory does not exist (for example if /var/run is a tmpfs and the host smbd was not started).

This leads to the following error message from samba
and an unworkable smbd:
Failed to create pipe directory /var/run/samba/ncalrpc - No such file
or directory

The attached patch fixes this by pointing smbd to /tmp/qemu-smb.%d.%d/ncalrpc as ncalrpc directory.
Smbd will create the actual ncalrpc subdirectory on its own.

Using a private directory also avoids possible clashes with the system-smbd.