Page 3 of 3 FirstFirst 123
Results 21 to 30 of 30

Thread: Client Pc to NFS Server

  1. #21
    Join Date
    Aug 2011
    Beans
    95
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Client Pc to NFS Server

    Quote Originally Posted by borjamf View Post
    Check this:

    - First, you have to bind the real directory on your server with the pseudo directory that you'll export to the client. For example:
    Directory on the server: /home/music
    Directory to export: /export/music
    Binding the directories: mount bind -t /home/music /export/music

    -
    Edit the /etc/exports file. Here is where you write the directory to share with the client.
    Code:
    /export ipclient(rw,fsid=0,no_subtree_check,sync)
                  /export/music ipclient(rw,no_subtree_check,sync,nohide)
    - Edit the /etc/fstab file and add this line, so you do not have to bind the directories every time when you reboot:
    Code:
     /home/music /export/music   none    bind  0  0
    - Now, go to the Client, edit the /etc/default/nfs-common (https://help.ubuntu.com/community/NFSv4Howto).

    - On the client, mount -t nfs4 IPSERVER:/music /directory/example/client

    CHECK if you have the directory /directory/example/client created.
    bstrizzy@nova:~$ sudo mount bind -t /home/music /export/music
    mount: unknown filesystem type '/home/music'
    bstrizzy@nova:~$ sudo mount bind -t /home/bstrizzy/music /export/music
    mount: unknown filesystem type '/home/bstrizzy/music'

    whyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy

  2. #22
    Join Date
    Oct 2008
    Location
    Ottawa, Canada
    Beans
    809
    Distro
    Xubuntu 16.04 Xenial Xerus

    Re: Client Pc to NFS Server

    The correct syntax is
    Code:
    sudo mount -o bind /home/bstrizzy/music /export/music
    /export/music must exists.

    That being said, this is overly complicated for a simple setup. Just export
    /home/bstrizzy/music *(rw,no_subtree_check,no_root_squash)
    Reload the NFS config with
    Code:
    sudo exportfs -ra
    Then on your client, mount the share (no need for -t nfs4)
    Code:
    sudo mount 192.168.1.7:/home/bstrizzy/music /home/bstrawt/Music
    To make it permanent in /etc/fstab, add this line
    Code:
    192.168.1.7:/home/bstrizzy/music /home/bstrawt/Music nfs defaults 0 0
    Cheers!
    husband@wife$ make sandwich
    Permission denied
    husband@wife$ sudo make sandwich

  3. #23
    Join Date
    Aug 2011
    Beans
    95
    Distro
    Ubuntu 12.04 Precise Pangolin

    Question Re: Client Pc to NFS Server

    Quote Originally Posted by LewisTM View Post
    The correct syntax is
    Code:
    sudo mount -o bind /home/bstrizzy/music /export/music
    /export/music must exists.

    That being said, this is overly complicated for a simple setup. Just export
    /home/bstrizzy/music *(rw,no_subtree_check,no_root_squash)
    Reload the NFS config with
    Code:
    sudo exportfs -ra
    Then on your client, mount the share (no need for -t nfs4)
    Code:
    sudo mount 192.168.1.7:/home/bstrizzy/music /home/bstrawt/Music
    To make it permanent in /etc/fstab, add this line
    Code:
    192.168.1.7:/home/bstrizzy/music /home/bstrawt/Music nfs defaults 0 0
    Cheers!
    yes this does seem over complicated, but now i got the bind and i get an access denied by server error. check my attatchments. the terminal in nano is the server

  4. #24
    Join Date
    Oct 2008
    Location
    Ottawa, Canada
    Beans
    809
    Distro
    Xubuntu 16.04 Xenial Xerus

    Re: Client Pc to NFS Server

    I don't see any attachment.
    Add insecure to your export options, then reload the NFS config with sudo exportfs -ra. That usually fixes it.
    husband@wife$ make sandwich
    Permission denied
    husband@wife$ sudo make sandwich

  5. #25
    Join Date
    Aug 2011
    Beans
    95
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Client Pc to NFS Server

    Quote Originally Posted by LewisTM View Post
    I don't see any attachment.
    Add insecure to your export options, then reload the NFS config with sudo exportfs -ra. That usually fixes it.
    whoops =) there ya go
    Attached Images Attached Images

  6. #26
    Join Date
    Oct 2008
    Location
    Ottawa, Canada
    Beans
    809
    Distro
    Xubuntu 16.04 Xenial Xerus

    Re: Client Pc to NFS Server

    Try these lines in your /etc/exports
    Code:
    /export 192.168.1.0/255.255.255.0(insecure,rw,fsid=0,nohide,no_subtree_check,sync)
    /export/music 192.168.1.0/255.255.255.0(insecure,rw,no_subtree_check,nohide,sync)
    husband@wife$ make sandwich
    Permission denied
    husband@wife$ sudo make sandwich

  7. #27
    Join Date
    Aug 2011
    Beans
    95
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Client Pc to NFS Server

    Quote Originally Posted by LewisTM View Post
    Try these lines in your /etc/exports
    Code:
    /export 192.168.1.0/255.255.255.0(insecure,rw,fsid=0,nohide,no_subtree_check,sync)
    /export/music 192.168.1.0/255.255.255.0(insecure,rw,no_subtree_check,nohide,sync)
    same error

  8. #28
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    12,629
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: Client Pc to NFS Server

    Quote Originally Posted by BStrizzy View Post
    bstrizzy@nova:~$ sudo mount bind -t /home/music /export/music
    mount: unknown filesystem type '/home/music'

    whyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
    Because you're not paying careful attention to the syntax people are suggesting here. The -t parameter expects a filesystem from that long list I gave you earlier. This has been a persistent issue in this thread.
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  9. #29
    Join Date
    Dec 2009
    Location
    germany
    Beans
    1,020
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Client Pc to NFS Server

    Quote Originally Posted by BStrizzy View Post
    same error
    hello
    it's a long to work with nfs. therefore you will find in the attachment instructions for you.
    this example works (sure) on a server running ubuntu 12.04.1 and the client is Ubuntu 10.04.
    much luck
    Attached Files Attached Files
    "What is the robbing of a bank compared to the FOUNDING of a bank?" Berthold Brecht

  10. #30
    Join Date
    Aug 2011
    Beans
    95
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Client Pc to NFS Server

    Quote Originally Posted by rnerwein View Post
    hello
    it's a long to work with nfs. therefore you will find in the attachment instructions for you.
    this example works (sure) on a server running ubuntu 12.04.1 and the client is Ubuntu 10.04.
    much luck

    awesome man, just checked this out and its a charm. Appreciate it!

Page 3 of 3 FirstFirst 123

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •