LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-23-2017, 11:56 AM   #1
chtsalid
Member
 
Registered: Jan 2017
Posts: 67

Rep: Reputation: Disabled
permanent smb mount with option guest


Hi,

I try to mount an smb with option guest using the fstab, but I receive an error. However using the mount.cifs command it mounts.

[root@rh2 ~]# mount.cifs //192.168.122.1/anonymous /mnt/smb -o guest
[root@rh2 ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/centos-root 7.6G 4.4G 3.3G 58% /
devtmpfs 905M 0 905M 0% /dev
tmpfs 920M 0 920M 0% /dev/shm
tmpfs 920M 8.8M 912M 1% /run
tmpfs 920M 0 920M 0% /sys/fs/cgroup
/dev/vda1 497M 213M 285M 43% /boot
192.168.122.1:/var/nfs 39G 11G 29G 27% /mnt/nfs
tmpfs 184M 0 184M 0% /run/user/0
//192.168.122.1/anonymous 39G 11G 29G 27% /mnt/smb
[root@rh2 ~]# umount /mnt/smb/


vi /etc/fstab
//192.168.122.1/anonymous /mnt/smb cifs guest defaults 0 0

ount: /etc/fstab: parse error: ignore entry at line 13.

any idea?

Many thanks!
 
Old 01-23-2017, 12:24 PM   #2
eSelix
Senior Member
 
Registered: Oct 2009
Location: Wroclaw, Poland
Distribution: Arch, Kubuntu
Posts: 1,261

Rep: Reputation: 315Reputation: 315Reputation: 315Reputation: 315
You have space between "guest" and "defaults". Maybe just remove option "defaults".
 
1 members found this post helpful.
Old 01-23-2017, 12:29 PM   #3
chtsalid
Member
 
Registered: Jan 2017
Posts: 67

Original Poster
Rep: Reputation: Disabled
Hi,

[root@rh2 ~]# mount -a
[root@rh2 ~]#
[root@rh2 ~]#
[root@rh2 ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/centos-root 7.6G 4.4G 3.3G 58% /
devtmpfs 905M 0 905M 0% /dev
tmpfs 920M 0 920M 0% /dev/shm
tmpfs 920M 8.8M 912M 1% /run
tmpfs 920M 0 920M 0% /sys/fs/cgroup
/dev/vda1 497M 213M 285M 43% /boot
192.168.122.1:/var/nfs 39G 11G 29G 27% /mnt/nfs
tmpfs 184M 0 184M 0% /run/user/0
//192.168.122.1/anonymous 39G 11G 29G 27% /mnt/smb


many thanks!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
guest to guest mount using nat and virtualbox pan64 Linux - Networking 1 08-28-2014 03:15 PM
smb.conf file - "map to guest / guest ok = yes" query. uncle-c Linux - Server 1 09-16-2009 09:44 AM
smb mount folders disappear on mount & konqueror smb fails: network unreachable tisource Linux - Networking 1 10-17-2007 12:30 AM
guest access to a share in smb.conf ?? ludeKing Linux - Networking 1 10-27-2003 01:36 PM
permanent mount jerrod Linux - Newbie 4 04-14-2003 06:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration