DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default NFS Troubles!!

Hi everyone I am currently having NFS set up trouble.
To give you a little background knowledge, I am trying to nfs on these computers:
192.168.1.66 the server
192.168.1.71 is the client.

This is my /etc/exports on 192.168.1.66
Code:
/usr/mount/350gb/  -maproot=disappearedng -alldirs -network  192.168.1.71
where the username is always disappearedng on 192.168.1.71.

showmount -e produces:
Code:
Exports list on localhost:
/usr/mount/350gb/                  192.168.1.71
So I restarted my computer, with
rpcbind_enable="YES"
nfs_server_enable="YES"
mountd_flags="-r"
in my /etc/rc.conf

On 192.168.1.71, I have done # nfsiod -n 4
and this is what I get when I try to mount
Code:
 
$sudo mount_nfs 192.168.1.66:/usr/mount/350gb /usr/imports/
Password:
[udp] 192.168.1.66:/usr/mount/350gb: Permission denied 
...
This is my /etc/fstab on the server
Code:
# Device        Mountpoint              FStype  Options         Dump    Pass#
/dev/ad4s4b     none                    swap    sw              0       0
/dev/ad4s4a     /                       ufs     rw              1       1
/dev/ad4s4e     /tmp                    ufs     rw              2       2
/dev/ad4s4f     /usr                    ufs     rw              2       2
/dev/ad4s4d     /var                    ufs     rw              2       2
/dev/ad4s1d     /usr/mount/50gb         ufs     rw              2       2
/dev/ad4s2d     /usr/mount/350gb        ufs     rw              2       2
/dev/acd0       /cdrom                  cd9660  ro,noauto       0       0
Why can't I mount??? (I HAVE FOLLOWED THE INSTRUCTIONS EXACTLY).

And how do I restart my nfsdaemon???
Do I need to restart mountd, nfsd and what else whenever I change /etc/exports and if yes, how do I do it?

(I know you can do this by sudo /etc/rc.d/nfsd stop)
Thx
Reply With Quote
  #2   (View Single Post)  
Old 11th September 2008
corey_james corey_james is offline
Uber Geek
 
Join Date: Apr 2008
Location: Brisbane, Australia
Posts: 238
Default

I see no log output - have you looked at the logs?
__________________
"No, that's wrong, Cartman. But don't worry, there are no stupid answers, just stupid people." -- Mr. Garrison

Forum Netiquette
Reply With Quote
  #3   (View Single Post)  
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default

I don't know how the logs will help me diagnose the problem...

How do you go about that? If yes, which logs should I look at? If the nfs server was NOT successfully connected, will logs be useful??
Reply With Quote
  #4   (View Single Post)  
Old 11th September 2008
Speedy Speedy is offline
Port Guard
 
Join Date: May 2008
Location: Pelican State
Posts: 23
Default

How about /var/log/messages in server.
Reply With Quote
  #5   (View Single Post)  
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default

OK I will take a look at that. (But I doubt i really will be able to find anything interesting there.)

Is there anything wrong with my /etc/exports? I hear that you can only export a location where it's the root of a partition. Is that true?

Notice that I have -maproot=disappearedng -alldirs -network on my /etc/exports. What exactly does maproot do? Does it enable root privileges to disappearedng? If i did not have that there, does that mean that my disappearedng on the client side does not have root privileges? Can disappearedng still be able to write on the exported driver even if maproot is off?
Reply With Quote
  #6   (View Single Post)  
Old 11th September 2008
Speedy Speedy is offline
Port Guard
 
Join Date: May 2008
Location: Pelican State
Posts: 23
Default

Remove all fancy options and try again. Once it's working add configuration options you need. Note, in most cases root access with root rights to network volumes is discouraged. Root account is a local administration account after all.
Reply With Quote
  #7   (View Single Post)  
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default

OK i have removed all the fancy options right now to simplify things:

now my /etc/exports looks like:
Code:
/usr/mount/350gb/                               192.168.1.71
with rc.conf
Code:
#NFS
rpcbind_enable="YES"
nfs_server_enable="YES"
mountd_flags="-r"
with /var/log/messages:
Code:
Sep 11 14:15:23  savecore: no dumps found
Sep 11 14:15:24  root: /etc/rc: WARNING: $dbus_enable is not set properly - see rc.conf(5).
Sep 11 14:15:25  avahi-daemon[832]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Sep 11 14:15:27  kernel: drm0: <Intel i945G> on vgapci0
Sep 11 14:15:27  kernel: info: [drm] AGP at 0xd0000000 256MB
Sep 11 14:15:27  kernel: info: [drm] Initialized i915 1.5.0 20060119
Sep 11 14:15:27  kernel: drm0: [ITHREAD]
Sep 11 14:16:08  console-kit-daemon[945]: GLib-CRITICAL: g_hash_table_lookup: assertion `hash_table != NULL' failed
Sep 11 14:16:08  console-kit-daemon[945]: GLib-CRITICAL: g_hash_table_destroy: assertion `hash_table != NULL' failed
Sep 11 14:17:07  mountd[686]: mount request denied from 192.168.1.71 for /usr/mount/350gb
Sep 11 14:17:28  mountd[686]: mount request denied from 192.168.1.71 for /usr/mount/350gb
Sep 11 14:18:56  su: BAD SU disappearedng to root on /dev/ttyp1
Sep 11 14:18:59  su: disappearedng to root on /dev/ttyp1
Sep 11 14:21:03  mountd[686]: mount request denied from 192.168.1.71 for /usr/mount/350gb
showmount -e shows
Code:
Exports list on localhost:
/usr/mount/350gb/                  192.168.1.71
But then on my client, I am getting:
Code:
sudo mount_nfs 192.168.1.66:/usr/mount/350gb/ /usr/imports/
[udp] 192.168.1.66:/usr/mount/350gb: Permission denied
????
Reply With Quote
  #8   (View Single Post)  
Old 11th September 2008
Speedy Speedy is offline
Port Guard
 
Join Date: May 2008
Location: Pelican State
Posts: 23
Default

Did you restart NFSD after changing exports file. Not sure if it changes anything, but I've never used trailing slash myself. /usr/mount/350gb maybe?

Snippet from my rc.conf
Code:
rpcbind_enable="YES"
nfs_server_enable="YES"
nfs_server_flags="-t -n 6 -h 192.168.2.254"
mountd_flags="-r"
rpc_lockd_enable="YES"
rpc_statd_enable="YES"
and my exports.
Code:
/usr/local/www          -network 192.168.2.0 -mask 255.255.255.0
/usr/local/portage      -maproot=root -network 192.168.2.0 -mask 255.255.255.0

Last edited by Speedy; 11th September 2008 at 07:06 PM.
Reply With Quote
  #9   (View Single Post)  
Old 11th September 2008
lvlamb's Avatar
lvlamb lvlamb is offline
Real Name: Louis V. Lambrecht
Spam Deminer
 
Join Date: May 2008
Location: .be
Posts: 221
Default

Which NFS version ? I suppose NFS3.
On the server: which OS, locale, NFS version.
On the client: which OS, locale, NFS version.
Two years ago, there was a "feature" on NFS3 which would mount a NFS share ro in case the file sytems used "different" code page/locale.
Most FTPs "translate", NFS does not.
__________________
da more I know I know I know nuttin'
Reply With Quote
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default

OK I think I might have discovered some problems>
So now my /etc/rc.conf is:
Code:
rpcbind_enable="YES"
nfs_server_enable="YES"
mountd_flags="-r"
rpc_lockd_enable="YES"
rpc_statd_enable="YES"
my /etc/exports
Code:
/usr/mount/350gb/       -mapall=root                    192.168.1.71
and from my logs
Code:
Sep 11 18:13:05  mountd[687]: mount request from 192.168.1.71 from unprivileged port
Sep 11 18:13:21  mountd[687]: mount request denied from 192.168.1.71 for /usr/mount/350gb
Sep 11 18:15:22  nfsd[1503]: can't bind udp addr *: Address already in use
Sep 11 18:15:32  nfsd[1513]: can't bind udp addr *: Address already in use
Sep 11 18:16:52  nfsd[1567]: can't bind udp addr *: Address already in use
I notice that there are a few nfsd pids. (Is that normal?)

and when I do the following on the client, I get
Code:
[disappearedng@ ~]$ sudo mount_nfs 192.168.1.66:/usr/mount/350gb/ /usr/imports/
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
[udp] 192.168.1.66:/usr/mount/350gb: RPCPROG_NFS: RPC: Program not registered
Which I think is related to "can't bind udp addr *: Address already in use"
Reply With Quote
Old 11th September 2008
disappearedng disappearedng is offline
Shell Scout
 
Join Date: May 2008
Posts: 128
Default

THANKS TO EVIL TOAST ON FreeBSDhelp on EFNET,
I found the problem

In my /etc/exports,
I have /usr/mount/350gb/
it's supposed to be /usr/mount/350gb (without the slash!!!) !!!

OMG this is so unbelievable
Reply With Quote
Old 12th September 2008
Speedy Speedy is offline
Port Guard
 
Join Date: May 2008
Location: Pelican State
Posts: 23
Default

Isn't this what I wrote in post #8? I've noticed before people do not read what I write. Gotta be something wrong with me ... maybe I just do not belong here ...
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Matlab R2008b via linuxulator in FreeBSD, Installation Troubles ninjatux FreeBSD General 2 24th March 2009 04:23 AM
window manager troubles techmarks FreeBSD General 3 29th September 2008 10:19 PM
Opera Widget Javascript Troubles thejosephgrace General software and network 6 3rd August 2008 01:34 PM


All times are GMT. The time now is 07:35 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick