Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED]cant start NFS: 'rpc.nfsd:unable to access /proc/fs/
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
jody
l33t
l33t


Joined: 16 Oct 2007
Posts: 668
Location: Switzerland

PostPosted: Mon Apr 04, 2011 4:52 pm    Post subject: [SOLVED]cant start NFS: 'rpc.nfsd:unable to access /proc/fs/ Reply with quote

Hi
I have a 64bit gentoo on my machine (2.6.36-gentoo-r5).
The nfs-utils has version 1.2.3-r1

I want to export a directory (/home/jody/share) for nfs to the
machines 192.168.168.32, 192.168.168.33, 192.168.168.34, and 192.168.168.35

So i have /etc/exports
Code:
/home/jody/share 192.168.168.32(rw,async,no_subtree_check) 192.168.168.33(rw,async,no_subtree_check) 192.168.168.34(rw,async,no_subtree_check) 192.168.168.35(rw,async,no_subtree_check)

and hosts.allow
Code:
lockd:   localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
portmap: localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
mountd:  localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
statd:   localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
idmapd:  localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
rquotad: localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35
sshd:    localhost,  192.168.168.32, 192.168.168.33, 192.168.168.34, 192.168.168.35


When i want to start nfs, i get an error:
Code:
localhost ~ # /etc/init.d/nfs start
 * Exporting NFS directories ...                                          [ ok ]
 * Starting NFS mountd ...                                                [ !! ]
 * Starting NFS daemon ...
rpc.nfsd: Unable to access /proc/fs/nfsd errno 2 (No such file or directory).
Please try, as root, 'mount -t nfsd nfsd /proc/fs/nfsd' and then restart rpc.nfsd to correct the problem                                                  [ !! ]
 * Starting NFS smnotify ...                                              [ ok ]


The starting of 'mountd' is marked as erroneous with '[!!]',
but i don't know if this is related to the other error of 'rpc.nfsd'.
Anyway, nfs isn't running.

When i try the suggestion given, this also fails:
Code:
localhost ~ # mount -t nfsd nfsd /proc/fs/nfsd
mount: unknown filesystem type 'nfsd'


Can anybody help me?

Thank You
Jody


Last edited by jody on Tue Apr 05, 2011 7:17 am; edited 1 time in total
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Apr 04, 2011 5:32 pm    Post subject: Reply with quote

Looks like kernel configuration problem, did you enable nfs support?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
jody
l33t
l33t


Joined: 16 Oct 2007
Posts: 668
Location: Switzerland

PostPosted: Tue Apr 05, 2011 7:16 am    Post subject: Reply with quote

Thanks! Indeed my .config had almost all NFS options enabled, but not NFSD:
Code:
CONFIG_NETWORK_FILESYSTEMS=y
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
CONFIG_NFS_V3_ACL=y
CONFIG_NFS_V4=y
# CONFIG_NFS_V4_1 is not set
CONFIG_ROOT_NFS=y
# CONFIG_NFS_USE_LEGACY_DNS is not set
CONFIG_NFS_USE_KERNEL_DNS=y
# CONFIG_NFSD is not set

I changed that, rebuilt the kernel, and now it works.

Thanks
Jody
Back to top
View user's profile Send private message
diablo465
Apprentice
Apprentice


Joined: 10 Sep 2013
Posts: 194

PostPosted: Sun Nov 09, 2014 11:23 pm    Post subject: Reply with quote

same problem here


mount -t nfsd nfsd /proc/fs/nfsd
Code:

mount: unknown filesystem type 'nfsd'


lsmod
Code:

Module                  Size  Used by
nfsv4                 252479  0
nfs                   158220  1 nfsv4
lockd                  61333  1 nfs
sunrpc                183749  3 nfs,lockd,nfsv4
nvidia              10491864  72
vboxnetflt             15666  0
vboxnetadp             17734  0
vboxdrv              1809437  2 vboxnetadp,vboxnetflt


ae429-1105 fs # grep -i "nfs" /usr/src/linux/.config
CONFIG_NFS_FS=m
Code:
CONFIG_NFS_V2=m
CONFIG_NFS_V3=m
CONFIG_NFS_V3_ACL=y
CONFIG_NFS_V4=m
# CONFIG_NFS_SWAP is not set
# CONFIG_NFS_V4_1 is not set
# CONFIG_NFS_FSCACHE is not set
# CONFIG_NFS_USE_LEGACY_DNS is not set
CONFIG_NFS_USE_KERNEL_DNS=y
# CONFIG_NFSD is not set
CONFIG_NFS_ACL_SUPPORT=m
CONFIG_NFS_COMMON=y
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Sun Nov 09, 2014 11:32 pm    Post subject: Reply with quote

Code:
# CONFIG_NFSD is not set

With this unset you can use this box as a client only.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
rajat.pandita
n00b
n00b


Joined: 24 May 2013
Posts: 10

PostPosted: Fri Nov 21, 2014 5:04 pm    Post subject: Works for me as well Reply with quote

Enabled CONFIG_NFSD in my Kernel Config and it works now.

Thanks :D
Back to top
View user's profile Send private message
yaxon
n00b
n00b


Joined: 14 Apr 2015
Posts: 4

PostPosted: Sun May 03, 2015 9:10 am    Post subject: Reply with quote

Такая же фигня и у меня

Code:
/etc/init.d/nfs start
 * Starting rpcbind ...                                                                                                                                                    [ ok ]
 * Starting NFS statd ...                                                                                                                                                  [ ok ]
 * Setting up RPC pipefs ...                                                                                                                                               [ ok ]
 * Starting idmapd ...                                                                                                                                                     [ ok ]
 * Exporting NFS directories ...                                                                                                                                           [ ok ]
 * Starting NFS mountd ...                                                                                                                                                 [ ok ]
 * Starting NFS daemon ...
rpc.nfsd: Unable to access /proc/fs/nfsd errno 2 (No such file or directory).
Please try, as root, 'mount -t nfsd nfsd /proc/fs/nfsd' and then restart rpc.nfsd to correct the problem                                                                   [ !! ]
 * Starting NFS smnotify ...                                                                                                                                               [ ok ]
 * ERROR: nfs failed to start

# mount -t nfsd nfsd /proc/fs/nfsd
mount: unknown filesystem type 'nfsd'

# grep -i "nfsd" /usr/src/linux/.config
CONFIG_NFSD=y
CONFIG_NFSD_V2_ACL=y
CONFIG_NFSD_V3=y
CONFIG_NFSD_V3_ACL=y
CONFIG_NFSD_V4=y
CONFIG_NFSD_V4_SECURITY_LABEL=y
# CONFIG_NFSD_FAULT_INJECTION is not set


Code:
# ls -l /usr/src/
lrwxrwxrwx  1 root root   20 май  2 12:45 linux -> linux-3.18.11-gentoo
 # uname -r
3.18.11-gentoo


При компиляции ядра вроде все верно делаю.
make && make modules_install && make install && reboot

Как узнать то ли ядро загрузилось ?
Может быть вообще при загрузке не то ядро грузится ?!

Дабы проэксперементировать...
я из ядра убрал опцию NFSD

Code:
# grep -i "nfsd" /usr/src/linux/.config
#
# mount -t nfsd nfsd /proc/fs/nfsd
mount: unknown filesystem type 'nfsd'
# modprobe nfsd
modprobe: FATAL: Module nfsd not found.

Тогда все четко, обратно добавляю в ядро NFSD

Далее.. решил я посмотреть чтож нам говорит rpc.nfsd
Code:

# rpc.nfsd -d
rpc.nfsd: Checking netconfig for visible protocols.
rpc.nfsd: Enabling inet udp.
rpc.nfsd: Enabling inet tcp.
rpc.nfsd: Enabling inet6 udp.
rpc.nfsd: Enabling inet6 tcp.
rpc.nfsd: Unable to access /proc/fs/nfsd errno 2 (No such file or directory).
Please try, as root, 'mount -t nfsd nfsd /proc/fs/nfsd' and then restart rpc.nfsd to correct the problem

# ls -ld /proc/fs/nfsd
dr-xr-xr-x 2 root root 0 май  3 12:53 /proc/fs/nfsd

Дык какой-же у него акцес должен быть ?!
Далее смотрю лог messages
Code:

May  3 12:50:36 srv rpc.statd[2679]: Version 1.3.1 starting
May  3 12:50:36 srv rpc.statd[2679]: Flags: TI-RPC
May  3 12:50:36 srv rpc.statd[2679]: Running as root.  chown /var/lib/nfs to choose different user
May  3 12:50:36 srv rpc.mountd[2750]: Version 1.3.1 starting
May  3 12:50:36 srv rpc.nfsd[2754]: error starting threads: errno 38 (Function not implemented)
May  3 12:50:36 srv sm-notify[2761]: Version 1.3.1 starting
May  3 12:50:36 srv /etc/init.d/nfs[2641]: ERROR: nfs failed to start
May  3 12:50:49 srv rpc.nfsd[2763]: error starting threads: errno 38 (Function not implemented)


прошло немного времени, чудил, крутил, мутил... завелось вроде бы
акцессы не трогал
Code:

 # rpc.nfsd -d
rpc.nfsd: Checking netconfig for visible protocols.
rpc.nfsd: Enabling inet udp.
rpc.nfsd: Enabling inet tcp.
rpc.nfsd: Enabling inet6 udp.
rpc.nfsd: Enabling inet6 tcp.
rpc.nfsd: knfsd is currently up



но не тут то было... на клиенте
Code:
mount server:/home /home
mount.nfs: Protocol not supported


тут я решил проверить что в ядре у клиента:
Code:
grep -i "nfs" /usr/src/linux/.config
CONFIG_KERNFS=y
CONFIG_NFS_FS=m
CONFIG_NFS_V2=m
CONFIG_NFS_V3=m
# CONFIG_NFS_V3_ACL is not set
# CONFIG_NFS_V4 is not set
# CONFIG_NFS_SWAP is not set
CONFIG_NFSD=m
CONFIG_NFSD_V3=y
# CONFIG_NFSD_V3_ACL is not set
# CONFIG_NFSD_V4 is not set
CONFIG_NFS_COMMON=y


перекомпилил, перезагрузился...
Code:
mount server:/home /home -v
mount.nfs: timeout set for Sun May  3 12:43:55 2015
mount.nfs: trying text-based options 'vers=4,addr=192.168.0.1,clientaddr=192.168.0.50'
mount.nfs: mount(2): Protocol not supported
mount.nfs: trying text-based options 'addr=192.168.0.1'
mount.nfs: prog 100003, trying vers=3, prot=6
mount.nfs: trying 192.168.0.1 prog 100003 vers 3 prot TCP port 2049
mount.nfs: portmap query retrying: RPC: Program/version mismatch
mount.nfs: prog 100003, trying vers=3, prot=17
mount.nfs: trying 192.168.0.1 prog 100003 vers 3 prot UDP port 2049
mount.nfs: portmap query failed: RPC: Program/version mismatch
mount.nfs: Protocol not supported
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum