Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 497278 - net-fs/ncpfs-2.2.6-r2 with sys-apps/util-linux-2.24 - mount: Can't write mount entry
Summary: net-fs/ncpfs-2.2.6-r2 with sys-apps/util-linux-2.24 - mount: Can't write moun...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Network Filesystems
URL: https://bugs.debian.org/cgi-bin/bugre...
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: 477498
  Show dependency tree
 
Reported: 2014-01-06 15:16 UTC by Juergen Rose
Modified: 2014-08-13 05:50 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Juergen Rose 2014-01-06 15:16:42 UTC
If I try to mount a novell share, 'mount' complains about:

root@leopard:/root(4)# grep mnt /etc/fstab | tr '\t' ' '
/dev/cdrom        /mnt/cdrom        auto   noauto,ro        0 0
/dev/fd0         /mnt/floppy        auto   noauto         0 0
ZELOS/rosej.MBB.ibmt    /mnt/v      ncp uid=root,gid=nwaccess,mode=660,owner=root,A=zelos,passwdfile=/etc/ncp-pass,noauto 0 0


root@leopard:/root(5)# mount /mnt/v/
Can't write mount entry

'df | grep /mnt' does not show any mounted novell filesystem:

root@leopard:/root(6)# df | grep /mnt

root@leopard:/root(6)# df
root@leopard:/root(7)# id
uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),11(floppy),26(tape),27(video)
root@leopard:/root(8)# type mount
mount is hashed (/bin/mount)
root@leopard:/root(9)# qfile -v /bin/mount
sys-apps/util-linux-2.24 (/bin/mount)


If I try to mount the Netware filesystem again, mount complains that it is already mounted:

root@leopard:/root(12)# mount /mnt/v/
You already have mounted server ZELOS
as user ROSEJ.MBB.IBMT
on mount point /mnt/v


But 'df' does not show it. This happens at least o two systems. If I try to list the contents of the /mnt/v directory, the contents is found:

root@lynx:/root(2)# mount /mnt/v/
Can't write mount entry
root@lynx:/root(3)# mount /mnt/v/
You already have mounted server ZELOS
as user ROSEJ.MBB.IBMT
on mount point /mnt/v
root@lynx:/root(4)# ll /mnt/v/
total 2
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 _ADMIN/
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 RAID1/
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 SYS/
root@lynx:/root(5)# qlist -Iv ncp
net-fs/ncpfs-2.2.6-r2


But some minutes later I get I/O error accessing this directory:


root@lynx:/root(10)# ll /mnt/v/
/bin/ls: reading directory /mnt/v/: Input/output error
total 0


root@leopard:/root(16)# ll /mnt/v/
/bin/ls: reading directory /mnt/v/: Input/output error
total 0
root@leopard:/root(17)# umount /mnt/v/
root@leopard:/root(18)# mount -v /mnt/v/
Can't get /etc/mtab~ lock file
root@leopard:/root(19)# ll /etc/mtab*
lrwxrwxrwx 1 root root   17 Sep  5 14:45 /etc/mtab -> /proc/self/mounts
-rw------- 1 root root    0 Jan  6 15:40 /etc/mtab~
-rw------- 1 root rose    0 Apr 25  2012 /etc/mtab.fuselock
-rw-r--r-- 1 root root 1459 Aug 22 15:50 /etc/mtab_saved
root@leopard:/root(20)# grep mnt /etc/fstab | tr '\t' ' '
/dev/cdrom        /mnt/cdrom              auto   noauto,ro        0 0
/dev/fd0         /mnt/floppy              auto   noauto         0 0
ZELOS/rosej.MBB.ibmt    /mnt/v                  ncp    uid=root,gid=nwaccess,mode=660,owner=root,A=zelos,passwdfile=/etc/ncp-pass,noauto 0 0
root@leopard:/root(21)# 
root@leopard:/root(21)# ll /mnt/v/
total 2
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 _ADMIN/
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 RAID1/
drwxrwx--- 1 root nwaccess 512 Jan  1  1986 SYS/


Any hint is appreciated.
Comment 1 Alexander Tsoy 2014-02-18 21:54:33 UTC
This is probably due to /etc/mtab -> /proc/self/mounts symlink. Looks like ncpfs uses standard glibc functions (addmntent()) to add mount point to mtab. If it's true, then this bug should block bug 477498
Comment 2 Alexander Tsoy 2014-02-18 22:21:52 UTC
I guess the following patch from debian should fix the issue: "drop-mtab-support"

http://ftp.de.debian.org/debian/pool/main/n/ncpfs/ncpfs_2.2.6-9.debian.tar.bz2
Comment 4 William Hubbs gentoo-dev 2014-08-09 20:20:17 UTC
This is the final blocker for bug #477498.
Can someone in net-fs please give us an update?

Thanks,

William
Comment 5 Alexander Tsoy 2014-08-12 10:00:05 UTC
1. This is a blocker for security bug 371477 as well.

2. ncpfs have been removed from debian (testing and unstable) [1], fedora [2], ubuntu (since 14.04) [3]. No new releases since 2005. Maybe it should be lastrited in Gentoo too?

[1] https://packages.debian.org/search?keywords=ncpfs
[2] http://pkgs.fedoraproject.org/cgit/ncpfs.git/commit/?id=6e2bd631e65c75ea7275db90ab6bfebcc042f1dd
[3] http://packages.ubuntu.com/search?keywords=ncpfs
Comment 6 Juergen Rose 2014-08-12 11:10:45 UTC
(In reply to Alexander Tsoy from comment #5)
> 1. This is a blocker for security bug 371477 as well.
> 
> 2. ncpfs have been removed from debian (testing and unstable) [1], fedora
> [2], ubuntu (since 14.04) [3]. No new releases since 2005. Maybe it should
> be lastrited in Gentoo too?
> 
> [1] https://packages.debian.org/search?keywords=ncpfs
> [2]
> http://pkgs.fedoraproject.org/cgit/ncpfs.git/commit/
> ?id=6e2bd631e65c75ea7275db90ab6bfebcc042f1dd
> [3] http://packages.ubuntu.com/search?keywords=ncpfs

Which possibilies to mount Netware would remain?
Comment 7 Joshua Kinard gentoo-dev 2014-08-12 11:44:03 UTC
I have NetWare VMs available that I can try to test with this weekend or such if I get time.  I've mounted NCP over IP before, but didn't have a lot of luck w/ IPX the one time I tried it.
Comment 8 Joshua Kinard gentoo-dev 2014-08-13 02:39:22 UTC
I've got this mostly fixed up, but I am trying to fix this QA notice:
 * QA Notice: Missing soname symlink(s):
 *
 *      usr/lib64/libncp.so.2.3 -> libncp.so.2.3.0
 *

Which is Bug #446696, but I'm not certain why the Makefile isn't creating that symlink properly.  Anyone better at Makefiles care to take a look?
Comment 9 Joshua Kinard gentoo-dev 2014-08-13 05:50:16 UTC
Fixed in ncpfs-2.2.6-r3.  Re-diffed the Debian mtab patch, and verified mounting a share via IPX to a NW4.2 server and via IP/UDP to a NW6.5 server.