[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#883976: marked as done (nfs-common: Shell script executed by systemd to mount net /home * /var fails)



Your message dated Sun, 10 Dec 2017 15:21:14 +0000
with message-id <1512919274.2723.4.camel@decadent.org.uk>
and subject line Re: Bug#883976: nfs-common: Shell script executed by systemd to mount net /home * /var fails
has caused the Debian Bug report #883976,
regarding nfs-common: Shell script executed by systemd to mount net /home * /var fails
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
883976: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=883976
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: nfs-common
Version: 1:1.3.4-2.1
Severity: grave
Justification: renders package unusable

Netboot file system on /devnfs (except that dev/nfs causes errors) so rootfs is mounted per fstab.
Trying to mount nfs file system for var and home and the mount fails.

When linux is fully up, and I'm logged into a user, su to root
the file systems can be mounted with no error message.

Why during boot are the messages:

mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/var  /var in /etc/fstab
mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/home /home in /etc/fstab

being generated as though the root id during boot is a normal unprivilaged unser?

fstab:

proc                                     /proc   proc    defaults                       0 0
/dev/mmcblk0p1                           /boot   vfat    defaults,ro                    0 2
#PARTUUID=62bc0a1f-02                    /       ext4    defaults,noatime               0 1
192.168.1.10:/nfsroot/r.32.test          /       nfs     defaults,rw                    0 0
#192.168.1.10:/nfsroot/b827eb/c23849/var  /var   nfs     defaults,rw                    0 0
#192.168.1.10:/nfsroot/b827eb/c23849/home /home   nfs     defaults,rw                    0 0
#browne:/nfsroot/b827eb/c23849/home      /home   nfs     defaults,rw                    0 0
tmpfs                                    /tmp    tmpfs   nodev,nosuid,size=1%,mode=1777 0 0

systemctl unit:

[Unit]
Description=Setup directory tree in var filesystem
DefaultDependencies=no
After=local-fs.target
Before=basic.target

[Service]
Type=oneshot
ExecStart=/usr/bin/setup-var-home.sh

[Install]
WantedBy=basic.target

hostname:
b827ebc23849

/usr/bin/setup-var-home.sh:
#!/bin/bash
H=$(hostname);
#H="b827ebc23849";
/bin/mount 192.168.1.10:/nsfroot/${H:0:-6}"/"${H:6:12}"/var  /var";
/bin/mount 192.168.1.10:/nsfroot/${H:0:-6}"/"${H:6:12}"/home /home";

systemctl status

● setup-var-home.service - Setup directory tree in var filesystem
   Loaded: loaded (/lib/systemd/system/setup-var-home.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sat 2017-12-09 13:43:43 PST; 22min ago
  Process: 267 ExecStart=/usr/bin/setup-var-home.sh (code=exited, status=1/FAILURE)
 Main PID: 267 (code=exited, status=1/FAILURE)

Dec 09 13:43:42 b827ebc23849 systemd[1]: Starting Setup directory tree in var filesystem...
Dec 09 13:43:43 b827ebc23849 setup-var-home.sh[267]: mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/var  /var in /etc/fstab
Dec 09 13:43:43 b827ebc23849 setup-var-home.sh[267]: mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/home /home in /etc/fstab
Dec 09 13:43:43 b827ebc23849 systemd[1]: setup-var-home.service: Main process exited, code=exited, status=1/FAILURE
Dec 09 13:43:43 b827ebc23849 systemd[1]: Failed to start Setup directory tree in var filesystem.
Dec 09 13:43:43 b827ebc23849 systemd[1]: setup-var-home.service: Unit entered failed state.
Dec 09 13:43:43 b827ebc23849 systemd[1]: setup-var-home.service: Failed with result 'exit-code'.

mount command output

192.168.1.10:/nfsroot/r.32.test on / type nfs (rw,relatime,vers=3,rsize=4096,wsize=4096,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.1.10,mountvers=3,mountp$
devtmpfs on /dev type devtmpfs (rw,relatime,size=405220k,nr_inodes=101305,mode=755)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,mode=755)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=27,pgrp=1,timeout=0,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,relatime,size=8200k)
/dev/mmcblk0p1 on /boot type vfat (ro,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,errors=remount-ro)
192.168.1.10:/nfsroot/b827eb/c23849/home on /home type nfs4 (rw,relatime,vers=4.0,rsize=131072,wsize=131072,namlen=255,hard,proto=tcp,port=0,timeo=600,retrans=2,sec=sys,clientaddr=192.168.1.$
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=81964k,mode=700,uid=1000,gid=1000)


-- Package-specific info:
-- rpcinfo --

-- System Information:
Distributor ID:	Raspbian
Description:	Raspbian GNU/Linux 9.1 (stretch)
Release:	9.1
Codename:	stretch
Architecture: armv7l

Kernel: Linux 4.9.59-v7+ (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages nfs-common depends on:
ii  adduser              3.115
ii  init-system-helpers  1.48
ii  keyutils             1.5.9-9
ii  libc6                2.24-11+deb9u1
ii  libcap2              1:2.25-1
ii  libcomerr2           1.43.4-2
ii  libdevmapper1.02.1   2:1.02.137-2
ii  libevent-2.0-5       2.0.21-stable-3
ii  libgssapi-krb5-2     1.15-1+deb9u1
ii  libk5crypto3         1.15-1+deb9u1
ii  libkeyutils1         1.5.9-9
ii  libkrb5-3            1.15-1+deb9u1
ii  libmount1            2.29.2-1
ii  libnfsidmap2         0.25-5.1
ii  libtirpc1            0.2.5-1.2
ii  libwrap0             7.6.q-26
ii  lsb-base             9.20161125+rpi1
ii  rpcbind              0.2.3-0.6
ii  ucf                  3.0036

Versions of packages nfs-common recommends:
ii  python  2.7.13-2

Versions of packages nfs-common suggests:
pn  open-iscsi  <none>
pn  watchdog    <none>

-- no debconf information

--- End Message ---
--- Begin Message ---
On Sat, 2017-12-09 at 14:32 -0800, Duncan Hare wrote:
> Package: nfs-common
> Version: 1:1.3.4-2.1
> Severity: grave
> Justification: renders package unusable
> 
> Netboot file system on /devnfs (except that dev/nfs causes errors) so
> rootfs is mounted per fstab.
> Trying to mount nfs file system for var and home and the mount fails.
> 
> When linux is fully up, and I'm logged into a user, su to root
> the file systems can be mounted with no error message.
> 
> Why during boot are the messages:
> 
> mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/var  /var in
> /etc/fstab
> mount: can't find 192.168.1.10:/nsfroot/b827eb/c23849/home /home in
> /etc/fstab
> 
> being generated as though the root id during boot is a normal
> unprivilaged unser?
[...]

Your script is only passing one argument to mount (you are quoting the
space that you probably intended to separate arguments).

Ben.

-- 
Ben Hutchings
Quantity is no substitute for quality, but it's the only one we've got.

Attachment: signature.asc
Description: This is a digitally signed message part


--- End Message ---

Reply to: