Author Topic: A little help with fstab (SOLVED)  (Read 8457 times)

0 Members and 1 Guest are viewing this topic.

Emegra

  • Guest
A little help with fstab (SOLVED)
« on: February 07, 2014, 07:20:59 pm »
Hi guys

Over the past few weeks I've been switching over from Freenas to Openmediavault on my NAS and it's finally done and stable at last, I have 6 shares all visible in Gigolo, I would like to mount the shares in /mnt which requires editing  /etc/fstab file something I'm not competent enough to do myself.

any help would be much appreciated


Many thanks


Graeme
« Last Edit: February 08, 2014, 08:07:00 am by Emegra »

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #1 on: February 07, 2014, 07:31:25 pm »
Okeydokey .. what's the output from:
Code: [Select]
sudo fdisk -l
and
Code: [Select]
sudo blkid
and
Code: [Select]
mount
and the current contents of
Code: [Select]
gedit /etc/fstab
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #2 on: February 07, 2014, 07:34:57 pm »
Code: [Select]
graeme@Linux1 ~ $ sudo fdisk -l
[sudo] password for graeme:

Disk /dev/sda: 360.1 GB, 360080695296 bytes
255 heads, 63 sectors/track, 43777 cylinders, total 703282608 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000001

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048   358106348   179052150+   7  HPFS/NTFS/exFAT
/dev/sda2       358107134   703281151   172587009    5  Extended
/dev/sda5       358107136   699107327   170500096   83  Linux
/dev/sda6       699109376   703281151     2085888   82  Linux swap / Solaris
graeme@Linux1 ~ $ sudo blkid
/dev/sda1: LABEL="Windows 7" UUID="02CAA59322478EE4" TYPE="ntfs"
/dev/sda5: UUID="034e3cfc-8511-446b-98eb-9e88283cf12a" TYPE="ext4"
/dev/sda6: UUID="50359b49-a810-460e-befa-9616af24bcba" TYPE="swap"
graeme@Linux1 ~ $ mount
/dev/sda5 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/cgroup type tmpfs (rw)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
udev on /dev type devtmpfs (rw,mode=0755)
devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
none on /run/shm type tmpfs (rw,nosuid,nodev)
none on /run/user type tmpfs (rw,noexec,nosuid,nodev,size=104857600,mode=0755)
gvfsd-fuse on /run/user/graeme/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,user=graeme)
graeme@Linux1 ~ $

Quote
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda5 during installation
UUID=034e3cfc-8511-446b-98eb-9e88283cf12a /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda6 during installation
UUID=50359b49-a810-460e-befa-9616af24bcba none            swap    sw              0       0

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #3 on: February 07, 2014, 07:57:19 pm »
Am I missing something .. I can only see one HDD there.
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #4 on: February 07, 2014, 08:29:22 pm »
Quote
Am I missing something .. I can only see one HDD there.

There is only one HDD, did you want that information from the PC or the NAS ?

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #5 on: February 07, 2014, 09:56:55 pm »
Oh, hang on .. you're trying to mount remote shares ?

has the NAS got a static IP ?

Can you mount the shares through gigolo .. THEN post the output from:
Code: [Select]
mount
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #6 on: February 07, 2014, 10:01:42 pm »
Quote
you're trying to mount remote shares ?

Yes

Quote
has the NAS got a static IP ?

Yes 192.168.2.50

Quote
Can you mount the shares through gigolo

Yes

Code: [Select]
graeme@Linux1 ~ $ mount
/dev/sda5 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/cgroup type tmpfs (rw)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
udev on /dev type devtmpfs (rw,mode=0755)
devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
none on /run/shm type tmpfs (rw,nosuid,nodev)
none on /run/user type tmpfs (rw,noexec,nosuid,nodev,size=104857600,mode=0755)
gvfsd-fuse on /run/user/graeme/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,user=graeme)
graeme@Linux1 ~ $


« Last Edit: February 07, 2014, 10:07:14 pm by Emegra »

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #7 on: February 07, 2014, 10:07:33 pm »
OK, that didn't give me what I wanted  :o .. were the shares mounted through gigolo when you ran "mount" to list the mounts ?

Do you know the path to the shares .. such as

//192.168.2.50/share/video
//192.168.2.50/share/music
etc ?

If not, navigate to the share in file manager .. then what does it say in the file manager address bar ?

[EDIT]

and do the shares require login credentials ?
« Last Edit: February 07, 2014, 10:16:14 pm by Mark Greaves (PCNetSpec) »
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #8 on: February 07, 2014, 10:17:55 pm »
Quote
Doyou know the path to the shares .. such as

They are all samba shares, on 192.168.2.50, the share names are

family-tree
graeme
pat
multimedia
movies
backups
utilities

Emegra

  • Guest
Re: A little help with fstab
« Reply #9 on: February 07, 2014, 10:21:32 pm »
Quote
and do the shares require login credentials ?

No they are all set for any user no password

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #10 on: February 07, 2014, 10:25:13 pm »
just to be 100% sure .. can you open file manager, and in the address bar enter:

smb://192.168.2.50/family-tree
and hit enter
then
smb://192.168.2.50/graeme
then
smb://192.168.2.50/pat
then
smb://192.168.2.50/multimedia
then
smb://192.168.2.50/movies
then
smb://192.168.2.50/backups
then
smb://192.168.2.50/utilities

were all the shares contents visible as expected ?
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #11 on: February 07, 2014, 10:29:10 pm »
Quote
were all the shares contents visible as expected ?

Yes

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #12 on: February 07, 2014, 10:34:51 pm »
OK, first let's create the mount points:
Code: [Select]
sudo mkdir -p /mnt/NAS
then
Code: [Select]
cd /mnt/NAS
then
Code: [Select]
sudo mkdir family-tree graeme pat multimedia movies backups utilities
close the terminal and confirm those directories exist in /mnt/NAS

or just post the output from:
Code: [Select]
ls -a /mnt
« Last Edit: February 07, 2014, 10:37:13 pm by Mark Greaves (PCNetSpec) »
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

Emegra

  • Guest
Re: A little help with fstab
« Reply #13 on: February 07, 2014, 10:37:20 pm »
ok thats worked fine all the share folders are located at /mnt/NAS

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 18255
  • Karma: 476
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: A little help with fstab
« Reply #14 on: February 07, 2014, 10:41:26 pm »
Backup fstab .. just in case:
Code: [Select]
sudo cp -v /etc/fstab /etc/fstab.backup

then we'll mount the sharesss through ftsab one at a time.
WARNING: You are logged into reality as 'root'
logging in as 'insane' is the only safe option.
pcnetspec.co.uk

 


SimplePortal 2.3.3 © 2008-2010, SimplePortal