A little system description, I have 2 SSD drives running raid 0 strictly for boot drives. I also have a 1tb HDD that I am trying to add to /etc/fstab on ubuntu 15.10.
Here is my entry into /etc/fstab
# /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>
/dev/mapper/isw_cdaafghhha_Volume0p2 / ext4 errors=remount-ro 0 1
/dev/mapper/isw_cdaafghhha_Volume0p1 /boot/efi vfat umask=0077 0 1
/dev/mapper/isw_cdaafghhha_Volume0p3 none swap sw 0 0
UUID=06c16279-3ef0-4c36-8879-d5e417324355 /media/brennan/06c16279-3ef0-4c36-8879-d5e417324355 ext3 defaults 0 0
Now when I run mount -a
I get
mount: /etc/fstab: parse error: ignore entry at line 11.
Any ideas?
Thanks!!
steeldriver
127k21 gold badges226 silver badges312 bronze badges
asked Feb 10, 2016 at 1:45
3
Use the blkid command to get UUID
root@ashu-700-430qe:/opt# blkid /dev/sdb3
/dev/sdb3: UUID="G6NJf4-YQGl-KikN-dMh7-2yUd-5Owf-4gCO2f" TYPE="LVM2_member"
then use this UUID in place of /dev/sdb3
I am just using my system as an example. It will be different in your case.
Make use of ‘tab’ to move from one column to another while editing /etc/fstab
and after that make sure that you issue
sudo update-initramfs -u
so that changes are available at boot time.
You can also try
mount -a
to verify your changes immediately.
This is how my /etc/fstab looks like
root@ashu-700-430qe:/opt# cat /etc/fstab
# /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/sda7 during installation
UUID=54458154-6f44-44c9-be44-f91d093d63e6 / ext4 errors=remount-ro 0 1
# /boot/efi was on /dev/sda2 during installation
UUID=E467-1A3B /boot/efi vfat defaults 0 1
# swap was on /dev/sda6 during installation
UUID=74a0518b-2eed-404a-aaa1-a302dbf9f18c none swap sw 0 0
#/dev/vgall/tmp /tmp ext4 defaults 0 2
#this is volume-opt
UUID=b3d302be-68f6-4804-abb1-ab806326b5a4 /opt ext4 defaults 0 2
#/dev/mapper/vgall-var
#UUID=35d84c0b-d29b-4677-bc0f-26ef945d1ebf /var ext4 defaults 0 1
#/dev/mapper/vgall-usr
#UUID=e67910d0-09c9-4249-ba20-c4e471b30e63 /usr ext4 defaults 0 2
#/dev/vgall/home
#/dev/mapper/vgall-home /home ext4 defaults 0 2
root@ashu-700-430qe:/opt#
You can use the above one as reference in terms of understanding the format.
answered Feb 10, 2016 at 1:52
AshuAshu
3,8277 gold badges24 silver badges50 bronze badges
1
Everything looks correct according to man fstab
, make sure you copy/paste the UUID & the last 2 (5th & 6th) fields aren’t required if zero.
I’d also go to the above line, delete the linebreak and press ENTER to insert it again, just to make sure it isn’t actually breaking things there.
Use sudo nano
or sudo vi
to edit it, to avoid hidden character encodings.
answered Feb 10, 2016 at 2:46
1
Recover Mode Read Only
I followed the next steps(Thank to @twister_void in this post ):
I did some web searching on «Recover Mode Read Only» and came across this post on LinuxQuestions.org website.
- Shutdown the computer
- Boot into Recovery Mode —After BIOS
load, hold down Shift key to access the grub menu —Once in grub
menu, select the entry ending in «(recovery mode)» - From the next menu selected option to enter Root Session
- At the root session, execute command mount -o rw,remount / to remount the filesystem as read-write
- Ignore error on step 4 like …parse error at line X …
Remove the line on /etc/fstab
-
Open the fstab file to remove the line X(in my case was line 1)
# nano /etc/fstab
-
Remove the line, you can use
ctrl+k
on nano editor - Save the file without the bad line
ctrl+x
andctrl+y
-
Reboot
# reboot
answered Aug 18, 2017 at 12:10
I have scrip with function:
mount_share () {
mkdir /data
echo //$STORAGE_NAME.file.core.windows.net/$STORAGE_SHARE /data cifs vers=3.0,username=$STORAGE_NAME,password=$STORAGE_KEY,dir_mode=0755,file_mode=0644,serverino >> /etc/fstab
mount -a
}
After execution — mount
returns me an error:
root@xx255rs2sptry000001:~# mount -a
mount: /etc/fstab: parse error: ignore entry at line 9.
Same error if I’m trying to sed
manually:
root@xx255rs2sptry000001:~# STORAGE_NAME=ggg
root@xx255rs2sptry000001:~# STORAGE_KEY=sakey
root@xx255rs2sptry000001:~# STORAGE_SHARE=sashare
root@xx255rs2sptry000001:~# echo //$STORAGE_NAME.file.core.windows.net/$STORAGE_SHARE /data cifs vers=3.0,username=$STORAGE_NAME,password=$STORAGE_KEY,dir_mode=0755,file_mode=0644,serverino >> /etc/fstab
root@xx255rs2sptry000001:~# cat /etc/fstab
# CLOUD_IMG: This file was created/modified by the Cloud Image build process
UUID=e990f8b3-1d6b-4615-8280-8ead4ed2fe7c / ext4 defaults,discard 0 0
# CLOUD_IMG: This file was created/modified by the Cloud Image build process
# The following is used to dynamically configured additional
# NICs. Do not remove unless you know what you are doing.
none /etc/network/interfaces.dynamic.d tmpfs nodev,noexec,nosuid,size=64K 0 0
/dev/disk/cloud/azure_resource-part1 /mnt auto defaults,nofail,x-systemd.requires=cloud-init.service,comment=cloudconfig 0 2
//ggg.file.core.windows.net/sashare /data cifs vers=3.0,username=ggg,password=sakey,dir_mode=0755,file_mode=0644,serverino
root@xx255rs2sptry000001:~# mount -a
mount: /etc/fstab: parse error: ignore entry at line 9.
I tried to close variables in «» — but no luck:
echo "//$STORAGE_NAME.file.core.windows.net/$STORAGE_SHARE /data cifs vers=3.0,username=$STORAGE_NAME,password=$STORAGE_KEY,dir_mode=0755,file_mode=0644,serverino" >> /etc/fstab
echo //"$STORAGE_NAME".file.core.windows.net/"$STORAGE_SHARE" /data cifs vers=3.0,username="$STORAGE_NAME",password="$STORAGE_KEY",dir_mode=0755,file_mode=0644,serverino >> /etc/fstab
And so on.
The entry in /etc/fstab
looks absolutely correct, but…
What I’m doing wrong here?
If add mount entry manually, with vim
and without variables — everything works fine.
Azure file share documentation — here.
Содержание
- Некорректный fstab и монтирование с полными правами для юзера
- Монтирую так
- Arch Linux
- #1 2014-08-09 18:18:55
- [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #2 2014-08-09 18:21:30
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #3 2014-08-09 18:45:03
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #4 2014-08-09 18:48:23
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #5 2014-08-09 19:03:12
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #6 2014-08-09 20:57:17
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #7 2014-08-09 21:06:20
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #8 2014-08-09 21:18:37
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #9 2014-08-09 22:27:59
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #10 2014-08-09 22:29:02
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #11 2014-08-09 22:47:35
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #12 2014-08-10 01:26:46
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #13 2014-08-10 01:28:46
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #14 2014-08-10 01:47:29
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #15 2014-08-10 01:54:58
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #16 2014-08-10 01:58:31
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #17 2014-08-10 02:04:34
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #18 2014-08-10 02:08:37
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #19 2014-08-10 02:11:31
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #20 2014-08-10 02:23:28
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #21 2014-08-10 02:27:16
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #22 2014-08-10 09:57:56
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- #23 2014-08-10 17:45:49
- Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
- Adding a disk to /etc/fstab getting a parse error
- 3 Answers 3
- Linux Mint Forums
- [SOLVED] NVME ssd no access
- [SOLVED] NVME ssd no access
- Re: NVME ssd no access
- Re: NVME ssd no access
- Re: NVME ssd no access
- Re: NVME ssd no access
Некорректный fstab и монтирование с полными правами для юзера
Монтирую расшаренную с помощью самбы папку. В /etc/fstab:
При вызове mount ругается на ошибку в этой строке.
Помогите пожалуйста разобраться, в чем проблема
user=user2,password=12345678, sec=ntlm, nofail, uid = 1001, rw, dmode = 777, fmode = 666
Как минимум, в этой части строки не должно быть никаких пробелов.
Выдается даже если сократить до такого
сработало,если заменить ntlm на ntlmssp, но при добавлении dmode и fmode опять invalid argument
Так в man mount.cifs об этих опциях ни слова — с чего ты взял, что они будут работать?
Монтирую так
Строчка из моего fstab
//192.168.1xx.xx/xxxxx /home/xxx cifs rw,iocharset=utf8,username=xxxxxx,password=xxxxxx,domain=xxxxxxx 0 0
вместо xxxxx свои символы
Спасибо большое! Заработало с параметрами sec=ntlmssp,dir_mode=0777,file_mode=0777.
мне было важно именно права прописать, там оказывается надо обязательно 0777,а не 777 и dir_mode вместо dmode. Ну и без пробелов везде. Спасибо!
Источник
Arch Linux
You are not logged in.
#1 2014-08-09 18:18:55
So I’ve been encountering this annoying issue with Arch so far that I haven’t been able to figure out. I have two extra internal hdds that do not mount at bootup. If I click on them in files, it prompts me to enter in my user password and then it will mount them in media as new volume and new volume1.
I edited my FSTAB to include the correct UUID and defaults under the options. However they do not mount at boot. I have to mount them manually which works fine, it’s just annoying as my dropbox folder is synced to my extra hdd, and it complains every time I login. Is there something I’m doing wrong? Thanks in advanced!
Last edited by 15goudreau (2014-08-10 17:46:00)
#2 2014-08-09 18:21:30
Post your /etc/fstab file contents and also the output of the «mount» command.
Edit: Also post the output of «lsblk -fs»
Last edited by headkase (2014-08-09 18:23:16)
#3 2014-08-09 18:45:03
for mounting I would use
Last edited by 15goudreau (2014-08-09 18:45:44)
#4 2014-08-09 18:48:23
You need to be using ntfs-3g as the filesystem type.
No, it didn’t «fix» anything. It just shifted the brokeness one space to the right. — jasonwryan
Closing — for deletion; Banning — for muppetry. — jasonwryan
Online
#5 2014-08-09 19:03:12
For the mount command, just:
By itself. Post the output of that.
#6 2014-08-09 20:57:17
@slithery are you sure for I just tried removing ntfs-3g and an fstab entry with type ntfs worked on boot.
The two failing ntfs mounts are under /run/media. So do the two mount points exist at the time the mounts are attempted.
There should be two failed mount units from systemd’s attempt to mount the filesystems
Should list the units so you can get the names and then
#7 2014-08-09 21:06:20
sudo systemctl —failed
changing to ntfs-3g didn’t work.
Last edited by 15goudreau (2014-08-09 21:10:08)
#8 2014-08-09 21:18:37
If you change one of the missing ntfs mounts mountpoints to /mnt just as a test does that allow it to mount on boot?
#9 2014-08-09 22:27:59
@ loqs. That did work. So why can’t I mount it to /media like arch wants. hmmm
#10 2014-08-09 22:29:02
the other drive that I tried to mount within the fstab gives me an error when trying to access it now.
#11 2014-08-09 22:47:35
@ loqs. That did work. So why can’t I mount it to /media like arch wants. hmmm
From your mount listing
/run being tmpfs (which is normal ) means it starts as an empty directory then populated with some entries by tmpfiles.d the rest of its contents comes from programs executing later in boot
So at the point the fstab is parsed and mount attempted it seems /run/media/taylor/New Volume and /run/media/taylor/New Volume1 do not exist so the mount fails.
From udisks2 looks like udisks2 is creating the paths and doing the mounting
Hope that explains it a little better
Edit:
If the new error is still occurring:
What command produced the new error?
Can you post /etc/fstab as it is now
Last edited by loqs (2014-08-09 23:16:47)
#12 2014-08-10 01:26:46
The error was occurring whenever I tried to mount it in fstab like that. I forgot to mention it in the OP. So is there nothing that can be done? It seems like a huge hassle to have to enter in a password to access my harddrives and on top of that have to relink dropbox each startup.
fstab as it is now
#13 2014-08-10 01:28:46
You do know that «ntfs» is built-into the kernel and provides read-only access. «ntfs-3g» is a separate package you install and provides both read and write access.
#14 2014-08-10 01:47:29
I understand headkase, but it didn’t work with ntfs or ntfs-3g. I can worry about read/write access after I get the drives to mount properly. Although with what loqs said above I’m not sure if I can.
#15 2014-08-10 01:54:58
You are putting the mount directly onto the /mnt folder, which is wrong.
Create a folder (before mounting) in /mnt, like say «/mnt/name» where «name» is your choice. Then in the fstab entry instead of «/mnt» replace that with «/mnt/name» so it doesn’t take the entire folder but rather mounts on the sub-folder.
#16 2014-08-10 01:58:31
You are mounting within your run/media/taylor folder. When the fstab is parsed, early in boot, this folder may not exist yet — it may only exist when you log into your user later on in the boot process. Try making a folder in /mnt, as instructed above, for this mountpoint too and changing the mountpoint to that folder. Because /mnt will always exist where the /run/media/* is not always guaranteed to exist.
#17 2014-08-10 02:04:34
right, but if I mount the drive to /mnt/folder, (I understand that it needs a folder «name») that will at least allow it to be mounted in the same place, which I guess is good for dropbox but then instead of having access through the File manager Devices I have to sift through computer>mnt>file. I know it seems like it is splitting hairs, and maybe I am just being difficult, but I feel like this isn’t the easiest most streamline way to get my drives mounted so that they can be seen under Devices, and I do not have to enter in my password each time.
#18 2014-08-10 02:08:37
Mountpoints need an empty folder to mount onto. So, /mnt/folder1 where «folder1» is empty then in your fstab you would have /mnt/folder1 as the location and when mounted the contents of folder1 would change from empty to whatever the contents of the mount had.
You can also put the mountpoints inside of your home folder if you like, just mount them onto some empty folders there. It might not matter but make sure / is first in fstab, followed by /home, and then followed by the mountpoints you could put in your home folder.
Depending on how your desktop environment mounts folders you could also edit your sudoers file so that «sudo mount» and «sudo umount» do not need a password. Again, depending on your environment, that might work.
Edit: put this in your sudoers (using visudo!):
Replace «bill» (my username) with your own.
Last edited by headkase (2014-08-10 02:11:09)
#19 2014-08-10 02:11:31
Mount them in a location that will exist during the boot process (/mnt can work, but creating a /media might be better and more flexible). Then just configure your file manager to display those folders in the side pane like it does folders under /run/username/media.
«UNIX is simple and coherent. » — Dennis Ritchie, «GNU’s Not UNIX» — Richard Stallman
#20 2014-08-10 02:23:28
That should work. It’s unfortunate that this is the workaround but it’ll will suffice for my purposes. Thanks guys for the help.
#21 2014-08-10 02:27:16
You’re welcome but you should see your thread through to fully solved. And when it is solved, not before, edit your first post and put «[Solved]» on the beginning of the title without quotes.
Last edited by headkase (2014-08-10 02:27:39)
#22 2014-08-10 09:57:56
If its enough that the filesystems are available on user login this should see the filesystems mounted where you want them under /run/media and probably show in your filemanager as expected
Create a script file or append this to one thats already executed on login
edit /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy
in the block starting
change allow_active to yes (from a script it may need allow_any instead not tested this)
This will stop udisksctl from producing a popup prompting for your password but obviously relaxes security on udisksctl
Last edited by loqs (2014-08-10 10:26:28)
#23 2014-08-10 17:45:49
Alright, so what I did was I created the directories /media/volume1 and /media/volume2 I edited my fstab to mount the drives there with the ntfs-3g (thanks headkase!). The nautilis file manager found the drives after I edited its configuration file. So now I can access the drives without being prompted for a password and dropbox links up without having to relink on reboot. Thanks all for the different suggestions and helping me troubleshoot! — marked solved.
Источник
Adding a disk to /etc/fstab getting a parse error
A little system description, I have 2 SSD drives running raid 0 strictly for boot drives. I also have a 1tb HDD that I am trying to add to /etc/fstab on ubuntu 15.10.
Here is my entry into /etc/fstab
Now when I run mount -a I get
3 Answers 3
Use the blkid command to get UUID
then use this UUID in place of /dev/sdb3 I am just using my system as an example. It will be different in your case. Make use of ‘tab’ to move from one column to another while editing /etc/fstab and after that make sure that you issue
so that changes are available at boot time.
You can also try mount -a to verify your changes immediately.
This is how my /etc/fstab looks like
You can use the above one as reference in terms of understanding the format.
Everything looks correct according to man fstab , make sure you copy/paste the UUID & the last 2 (5th & 6th) fields aren’t required if zero.
I’d also go to the above line, delete the linebreak and press ENTER to insert it again, just to make sure it isn’t actually breaking things there.
Use sudo nano or sudo vi to edit it, to avoid hidden character encodings.
Recover Mode Read Only
I followed the next steps(Thank to @twister_void in this post ):
I did some web searching on «Recover Mode Read Only» and came across this post on LinuxQuestions.org website.
- Shutdown the computer
- Boot into Recovery Mode —After BIOS load, hold down Shift key to access the grub menu —Once in grub menu, select the entry ending in «(recovery mode)»
- From the next menu selected option to enter Root Session
- At the root session, execute command mount -o rw,remount / to remount the filesystem as read-write
- Ignore error on step 4 like . parse error at line X .
Remove the line on /etc/fstab
Open the fstab file to remove the line X(in my case was line 1)
Remove the line, you can use ctrl+k on nano editor
Источник
Linux Mint Forums
Welcome to the Linux Mint forums!
[SOLVED] NVME ssd no access
[SOLVED] NVME ssd no access
Post by iiro_k » Fri Nov 11, 2022 8:48 am
So, built a new computer and booted from a previous SSD which had the Linux installed. The system clearly sees the SSD, but gives me no access to it.
Running the lsblk gives me this
Nvme is clearly seen on the last row, but i have no idea on what to doo next. Tried fiddling in bios, but no use. It does allow me to access it as a main user, but wont give me any options more then look around. It seems to be set as root.
Any ideas on how to proceed?
Re: NVME ssd no access
Post by iiro_k » Fri Nov 11, 2022 8:59 am
Re: NVME ssd no access
Post by AndyMH » Fri Nov 11, 2022 9:49 am
A bare SSD is going to be blank, use either gparted or disks to create a partition table on it and then create partitions as required.
The drive is not showing any partitions and you cannot mount a drive, if you had any partitions on it they would show as nvme0n1p1, nvme0n1p2, etc.
Re: NVME ssd no access
Post by iiro_k » Fri Nov 11, 2022 1:28 pm
Re: NVME ssd no access
Post by AndyMH » Fri Nov 11, 2022 3:11 pm
You are getting there, but syntax on mount and fstab wrong. You can mount a partition anywhere in the linux filesystem but the mountpoint must exist first. So in your case you need to create the folder /mnt/mydrive . Style points for the mountpoint = all lower case (linux is case sensitive) no spaces = keep it simple. Outside of /home/you and media/you everything else in the filesystem is owned by root so you need admin privileges to do it. The root account is disabled by default in mint (more secure) so you would use sudo to give yourself temporary admin privileges, i.e. sudo mkdir /mnt/mydrive . The GUI way, just open your file manager, navigate to / and right click on /mnt and ‘open as root’, then you can right click and create new folder.
Accepted practice (can be ignored) is either to mount partitions in /mnt or /media , or if it is a data partition /home/you/somewhere might be more useful, your choice.
Once you have the mountpoint then for fixed internal drives best way is to edit fstab so it mounts on boot. This is an entry in my fstab for an ext4 partition on an internal drive:
Using the UUID is better than /dev/nvme0n1p1 because device names are not fixed in linux, it depends on what order devices get reported to the system on boot. You get the UUID as an output from blkid . DO NOT try to retype, copy/paste from the terminal.
The easiest way to edit fstab, open your file manager, navigate to / and right click on /etc and ‘open as root’, scroll down and double click on fstab to edit*. Always a good idea to make a copy of fstab before you make changes, that way, screw up and the system won’t boot, you can boot your mint install stick, open the file manager, navigate to /etc on your system disk, delete fstab and rename the copy.
Yes you can use the mount command, syntax slightly different to fstab, but fstab is the better way. My example is for an ext4 partition, if you use ntfs (or exfat), options are slightly different.
Without all the above, in your file manager (nemo if running cinnamon) the partition should show up in the devices pane on the left as xxGB volume. Click on it to mount. It will mount at /media/you/the_UUID . Not user friendly, so a tip, whenever you create a partition give it a label, e.g. mylabel, then it will show in the file manager as mylabel and mount at /media/you/mylabel .
Any problems report back what you did. If you find that your partition mounts read-only, that is easy to fix.
Final tip — you used a msdos/legacy partition table, that is fine but there are limitations. If you have a drive > 2TB (you don’t) you must use a GPT partition table and a legacy partition table is limited to 4 primary partitions.
* quicker, in a terminal xed admin:/etc/fstab change xed to your text editor if not running cinnamon.
Источник
Forum rules
Before you post please read how to get help. Topics in this forum are automatically closed 6 months after creation.
-
Netherprovinc3
- Level 4
- Posts: 456
- Joined: Mon Feb 04, 2019 9:29 pm
fstab parse error [solved]
I have a 2nd internal drive and my problem all along with that drive is that at least one of the partitions seems to mount as root when I boot my computer. So, I always had to unmount the partition using sudo and remount it (which would remount it as the user that I am logged in as).
Here is the thread where that issue was uncovered (though I don’t think it’s relevant to this post)
viewtopic.php?f=231&t=346868
I created a folder in media to mount the partition and put my user as the owner and the group.
Next, I added some characters to /etc/fstab
Here is how fstab looks
when I scroll past the $ sign, here is the rest of the line
s 0 0
(each of these characters is separated by a tab)
when I run
terminal responds
Code: Select all
mount: /etc/fstab: parse error at line 13 -- ignored
Any ideas where I might have gone wrong?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
-
HaveaMint
- Level 6
- Posts: 1086
- Joined: Fri Feb 02, 2018 9:56 pm
Re: fstab parse error
Post
by HaveaMint » Mon May 24, 2021 4:14 pm
Netherprovinc3 wrote: ↑
Mon May 24, 2021 3:49 pm
Any ideas where I might have gone wrong?
It appears that the end of your line 13 is the problem. it is «defaults» not «default$»
Code: Select all
UUID=f4xxxf4c-7079-4900-94fa-bdcb164c5fa7 /media/user/Id2ExSpace ext4 defaults 0 2
«Tune for maximum Smoke and then read the Instructions».
-
Netherprovinc3
- Level 4
- Posts: 456
- Joined: Mon Feb 04, 2019 9:29 pm
Re: fstab parse error
Post
by Netherprovinc3 » Mon May 24, 2021 4:37 pm
HaveaMint wrote: ↑
Mon May 24, 2021 4:14 pm
Netherprovinc3 wrote: ↑
Mon May 24, 2021 3:49 pm
Any ideas where I might have gone wrong?It appears that the end of your line 13 is the problem. it is «defaults» not «default$»
Code: Select all
UUID=f4xxxf4c-7079-4900-94fa-bdcb164c5fa7 /media/user/Id2ExSpace ext4 defaults 0 2
No.
I have «defaults»
The screen shot that I provided is from using nano.
It seems nano puts a $ sign at the end of a line when there are additional characters on the line that don’t fit on the screen. s 0 0 (with tab spacing in between is cut off on the line).
I put 0 0 instead of 0 2 like you have.
I was following this tutorial, which seemed to be a really good tutorial for people on the novice level.
https://www.youtube.com/watch?v=JS0Jd_DNXdg
Last edited by Netherprovinc3 on Mon Jun 28, 2021 3:28 pm, edited 1 time in total.
-
altair4
- Level 20
- Posts: 11021
- Joined: Tue Feb 03, 2009 10:27 am
Re: fstab parse error
Post
by altair4 » Mon May 24, 2021 4:56 pm
Take a look at the first section of HaveaMint’s correction:
UUID=f4xxxf4c-7079-4900-94fa-bdcb164c5fa7
Now look at yours:
You have a space between UUID
and =
. And another space between that =
and the 93....
That’s the parse error.
Remove the spaces.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
-
Netherprovinc3
- Level 4
- Posts: 456
- Joined: Mon Feb 04, 2019 9:29 pm
Re: fstab parse error
Post
by Netherprovinc3 » Mon May 24, 2021 6:53 pm
altair4 wrote: ↑
Mon May 24, 2021 4:56 pm
You have a space betweenUUID
and=
. And another space between that=
and the93....
That’s the parse error.
Remove the spaces.
Thanks. That worked.
I like your screen name. I read that book a couple of months ago.
Некорректный fstab и монтирование с полными правами для юзера
Монтирую расшаренную с помощью самбы папку. В /etc/fstab:
При вызове mount ругается на ошибку в этой строке.
Помогите пожалуйста разобраться, в чем проблема
user=user2,password=12345678, sec=ntlm, nofail, uid = 1001, rw, dmode = 777, fmode = 666
Как минимум, в этой части строки не должно быть никаких пробелов.
Выдается даже если сократить до такого
сработало,если заменить ntlm на ntlmssp, но при добавлении dmode и fmode опять invalid argument
Так в man mount.cifs об этих опциях ни слова — с чего ты взял, что они будут работать?
Монтирую так
Строчка из моего fstab
//192.168.1xx.xx/xxxxx /home/xxx cifs rw,iocharset=utf8,username=xxxxxx,password=xxxxxx,domain=xxxxxxx 0 0
вместо xxxxx свои символы
Спасибо большое! Заработало с параметрами sec=ntlmssp,dir_mode=0777,file_mode=0777.
мне было важно именно права прописать, там оказывается надо обязательно 0777,а не 777 и dir_mode вместо dmode. Ну и без пробелов везде. Спасибо!
Источник
Arch Linux
You are not logged in.
#1 2014-08-09 18:18:55
[Solved] Internal extra hdd’s fail to mount at boot with FSTAB
So I’ve been encountering this annoying issue with Arch so far that I haven’t been able to figure out. I have two extra internal hdds that do not mount at bootup. If I click on them in files, it prompts me to enter in my user password and then it will mount them in media as new volume and new volume1.
I edited my FSTAB to include the correct UUID and defaults under the options. However they do not mount at boot. I have to mount them manually which works fine, it’s just annoying as my dropbox folder is synced to my extra hdd, and it complains every time I login. Is there something I’m doing wrong? Thanks in advanced!
Last edited by 15goudreau (2014-08-10 17:46:00)
#2 2014-08-09 18:21:30
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
Post your /etc/fstab file contents and also the output of the «mount» command.
Edit: Also post the output of «lsblk -fs»
Last edited by headkase (2014-08-09 18:23:16)
#3 2014-08-09 18:45:03
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
for mounting I would use
Last edited by 15goudreau (2014-08-09 18:45:44)
#4 2014-08-09 18:48:23
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
You need to be using ntfs-3g as the filesystem type.
No, it didn’t «fix» anything. It just shifted the brokeness one space to the right. — jasonwryan
Closing — for deletion; Banning — for muppetry. — jasonwryan
#5 2014-08-09 19:03:12
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
For the mount command, just:
By itself. Post the output of that.
#6 2014-08-09 20:57:17
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
@slithery are you sure for I just tried removing ntfs-3g and an fstab entry with type ntfs worked on boot.
The two failing ntfs mounts are under /run/media. So do the two mount points exist at the time the mounts are attempted.
There should be two failed mount units from systemd’s attempt to mount the filesystems
Should list the units so you can get the names and then
#7 2014-08-09 21:06:20
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
sudo systemctl —failed
changing to ntfs-3g didn’t work.
Last edited by 15goudreau (2014-08-09 21:10:08)
#8 2014-08-09 21:18:37
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
If you change one of the missing ntfs mounts mountpoints to /mnt just as a test does that allow it to mount on boot?
#9 2014-08-09 22:27:59
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
@ loqs. That did work. So why can’t I mount it to /media like arch wants. hmmm
#10 2014-08-09 22:29:02
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
the other drive that I tried to mount within the fstab gives me an error when trying to access it now.
#11 2014-08-09 22:47:35
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
@ loqs. That did work. So why can’t I mount it to /media like arch wants. hmmm
From your mount listing
/run being tmpfs (which is normal ) means it starts as an empty directory then populated with some entries by tmpfiles.d the rest of its contents comes from programs executing later in boot
So at the point the fstab is parsed and mount attempted it seems /run/media/taylor/New Volume and /run/media/taylor/New Volume1 do not exist so the mount fails.
From udisks2 looks like udisks2 is creating the paths and doing the mounting
Hope that explains it a little better
Edit:
If the new error is still occurring:
What command produced the new error?
Can you post /etc/fstab as it is now
Last edited by loqs (2014-08-09 23:16:47)
#12 2014-08-10 01:26:46
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
The error was occurring whenever I tried to mount it in fstab like that. I forgot to mention it in the OP. So is there nothing that can be done? It seems like a huge hassle to have to enter in a password to access my harddrives and on top of that have to relink dropbox each startup.
fstab as it is now
#13 2014-08-10 01:28:46
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
You do know that «ntfs» is built-into the kernel and provides read-only access. «ntfs-3g» is a separate package you install and provides both read and write access.
#14 2014-08-10 01:47:29
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
I understand headkase, but it didn’t work with ntfs or ntfs-3g. I can worry about read/write access after I get the drives to mount properly. Although with what loqs said above I’m not sure if I can.
#15 2014-08-10 01:54:58
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
You are putting the mount directly onto the /mnt folder, which is wrong.
Create a folder (before mounting) in /mnt, like say «/mnt/name» where «name» is your choice. Then in the fstab entry instead of «/mnt» replace that with «/mnt/name» so it doesn’t take the entire folder but rather mounts on the sub-folder.
#16 2014-08-10 01:58:31
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
You are mounting within your run/media/taylor folder. When the fstab is parsed, early in boot, this folder may not exist yet — it may only exist when you log into your user later on in the boot process. Try making a folder in /mnt, as instructed above, for this mountpoint too and changing the mountpoint to that folder. Because /mnt will always exist where the /run/media/* is not always guaranteed to exist.
#17 2014-08-10 02:04:34
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
right, but if I mount the drive to /mnt/folder, (I understand that it needs a folder «name») that will at least allow it to be mounted in the same place, which I guess is good for dropbox but then instead of having access through the File manager Devices I have to sift through computer>mnt>file. I know it seems like it is splitting hairs, and maybe I am just being difficult, but I feel like this isn’t the easiest most streamline way to get my drives mounted so that they can be seen under Devices, and I do not have to enter in my password each time.
#18 2014-08-10 02:08:37
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
Mountpoints need an empty folder to mount onto. So, /mnt/folder1 where «folder1» is empty then in your fstab you would have /mnt/folder1 as the location and when mounted the contents of folder1 would change from empty to whatever the contents of the mount had.
You can also put the mountpoints inside of your home folder if you like, just mount them onto some empty folders there. It might not matter but make sure / is first in fstab, followed by /home, and then followed by the mountpoints you could put in your home folder.
Depending on how your desktop environment mounts folders you could also edit your sudoers file so that «sudo mount» and «sudo umount» do not need a password. Again, depending on your environment, that might work.
Edit: put this in your sudoers (using visudo!):
Replace «bill» (my username) with your own.
Last edited by headkase (2014-08-10 02:11:09)
#19 2014-08-10 02:11:31
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
Mount them in a location that will exist during the boot process (/mnt can work, but creating a /media might be better and more flexible). Then just configure your file manager to display those folders in the side pane like it does folders under /run/username/media.
«UNIX is simple and coherent. » — Dennis Ritchie, «GNU’s Not UNIX» — Richard Stallman
#20 2014-08-10 02:23:28
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
That should work. It’s unfortunate that this is the workaround but it’ll will suffice for my purposes. Thanks guys for the help.
#21 2014-08-10 02:27:16
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
You’re welcome but you should see your thread through to fully solved. And when it is solved, not before, edit your first post and put «[Solved]» on the beginning of the title without quotes.
Last edited by headkase (2014-08-10 02:27:39)
#22 2014-08-10 09:57:56
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
If its enough that the filesystems are available on user login this should see the filesystems mounted where you want them under /run/media and probably show in your filemanager as expected
Create a script file or append this to one thats already executed on login
edit /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy
in the block starting
change allow_active to yes (from a script it may need allow_any instead not tested this)
This will stop udisksctl from producing a popup prompting for your password but obviously relaxes security on udisksctl
Last edited by loqs (2014-08-10 10:26:28)
#23 2014-08-10 17:45:49
Re: [Solved] Internal extra hdd’s fail to mount at boot with FSTAB
Alright, so what I did was I created the directories /media/volume1 and /media/volume2 I edited my fstab to mount the drives there with the ntfs-3g (thanks headkase!). The nautilis file manager found the drives after I edited its configuration file. So now I can access the drives without being prompted for a password and dropbox links up without having to relink on reboot. Thanks all for the different suggestions and helping me troubleshoot! — marked solved.
Источник
Thread: /etc/fstab bind not mounting
Thread Tools
Display
/etc/fstab bind not mounting
I am trying to mount a folder on startup with /etc/fstab but i keep getting this error
mount: /etc/fstab: parse error at line 14 — ignored
this is my /etc/fsta file
Last edited by DuckHook; January 12th, 2017 at 03:40 AM . Reason: Added [CODE] tags, removed interfering formatting
Re: /etc/fstab bind not mounting
Is it my imagination (or font) or is there a space between «defaults,» and «bind»? There should be no spaces in the list of options.
johnny would also need read-write permission for /steam.
Last edited by efflandt; January 9th, 2017 at 12:20 AM .
Re: /etc/fstab bind not mounting
I do have read and right permission for /steam.
there was a space so I removed it and no longer get the error but it still doesn’t mount the folder.
if i run mount manual
it works with no errors.
the line in /etc/fstab now looks like
Last edited by DuckHook; January 12th, 2017 at 03:42 AM . Reason: Added [CODE] tags, removed interfering formatting
Re: /etc/fstab bind not mounting
I think your issue may be the trailing slash.
Last edited by DuckHook; January 12th, 2017 at 03:42 AM . Reason: Added [CODE] tags, removed interfering formatting
Re: /etc/fstab bind not mounting
You still have a space between defaults, and bind.
There should be no space after the comma. The defaults option is redundant anyways.
This is functionally equivalent to doing it with the defaults option specified.
Last edited by jerome1232; January 10th, 2017 at 06:07 PM .
«You can’t expect to hold supreme executive power just because some watery tart lobbed a sword at you»
«Don’t let your mind wander — it’s too little to be let out alone.»
Источник
[SOLVED] Help With Setting Up Storage For Access In LXCs and Networked Machines
astarte
New Member
Hi everyone, new to Proxmox and Linux as a whole.
Over the last week or so, I’ve been trying to setup my storage (among other things). While I’ve been largely successful at setting up the rest of my server, setting up my storage the way I want has been a huge challenge.
What I want is:
- All 5 of my internal NTFS HDDs displayed in Proxmox and accessible by my host node, all my LXCs as well as the machines on my local network.
- I will be reformating these SATA HDDs to ext4 at some point in the future once I get a 6th HDD and am able to move files off them. For now, NTFS.
- Any USB Drives I plug in, regardless of format (most likely NTFS for compatibility with Windows and other devices) must be ‘plug and play’.
- Time efficiency.
What I did and what worked:
- Installed ntfs-3g on host node.
- I checked every LXC with ntfs-3g —version and it looks like its installed on every LXC as well as the host node?
- Mounted an NTFS USB Flash Drive to my host node.
- Added the USB Drive to /etc/fstab so that it would auto mount
- Created a privileged LXC and installed Samba on that LXC.
- Mounted that USB Drive onto the Samba LXC and created a share for the whole drive.
- This USB Drive is now visible on my Windows PC from my Proxmox box. Excellent.
- Created a privileged LXC for Plex Media Server.
- Enabled «cifs» in LXC features.
- Installed smbclient and cifs-utils on my Plex LXC.
- I can see all the shares I created on the smb LXC by typing smbclient -L
- Successfully mount the USB Drive share that is mounted on the Samba LXC to the Plex LXC using the following command:
- mount -t cifs -o username=x,password=x,uid=x,gid=x,vers=3.0,iocharset=utf8 «//192.168.0.x/Josh’s USB» /mnt/drives/usb-key/
- It seems USB Drive is ‘plug and play’.
What did not work for me:
- The mounted share on the Plex LXC disappears after reboot of LXC/server because I do not have an /etc/fstab entry.
- I was hoping that adding the entry to the Samba LXC /etc/fstab would work, but it does not. Since it doesn’t, this makes mounting shares to my LXCs 100x more tedious since I would have to edit /etc/fstab for every LXC and add an entry for every mount I want to share. Unless I’m missing something and the Samba server /etc/fstab really is where you add the entries. The command below is what I entered:
- «//192.168.0.x/Josh’s USB» /mnt/drives/usb2C-key/ cifs _netdev,x-systemd.automount,x-systemd.requires=network-online.target,uid=x,gid=x,username=x,password=x,vers=3.0,iocharset=utf8 0 0
- Note: I get an error when I enter the command mount -a with the above in my /etc/fstab .
- The error: mount: /etc/fstab: parse error at line 1 — ignored
- I decided to change course and try to add CIFS storage via the Proxmox WebUI.
- It seems the Proxmox WebUI does not like shares with spaces in their name. The share I created for my USB Drive comes up as «USB» not «Josh’s USB».
- Trying to add that share spits out an error: create storage failed: error during cfs-locked ‘file-storage_cfg’ operation: storage ‘usb-key’ is not online (500)
- However, using the pvesm command works perfectly. Full command below.
- pvesm add cifs usb-key —server 192.168.0.103 —share «Josh’s USB» —username x —password x —smbversion 3.0
- I do not know where to go from here though. Is this even what I want? Would I still need to edit /etc/fstab endlessly?
- While I was at it, I tried to add some shares from my Windows machine and it also seems there’s weird crap going on there too.
- Many of my Windows shares are labelled according to the drive that they are on. So my Backup folder on my «Storage 3» drive is named «[S3]Backup». When I shared that on my home network, Windows renames and shares it as «S3 Backup».
- I have 7 Backup folders (7 drives). Proxmox WebUI detects one as «Backup». I do not know which folder that is, specifically.
- When I try to add the Backup folder that Proxmox detects, I get an error:
- create storage failed: error during cfs-locked ‘file-storage_cfg’ operation: storage ‘backup’ is not online (500)
- That error is the same for every share, except for one share that is a folder without spaces or square brackets in the share or actual folder name. That share is detected correctly by Proxmox.
- Unlike above where pvesm worked, sharing «Josh’s USB», I get the same error as with the WebUI.
Wat do? I know I can just bind mount all my drives directly from my host node into every LXC but that’s such a huge waste of time and also redundant. So is editing every LXC’s /etc/fstab for Samba sharing. Is there no better, cleaner way to do what I want? Also, why aren’t my Windows share’s being added? Proxmox bug? Or does Linux simply not like square brackets and spaces?
Источник
# |
|
Темы: 3 Сообщения: 151 Участник с: 15 сентября 2016 |
findmnt: /etc/fstab: parse error at line 1 — ignored О чём это,поиск ничего вразумительного не даёт. |
vs220 |
# |
Темы: 22 Сообщения: 8090 Участник с: 16 августа 2009 |
Ну так покажите fstab |
Slav164 |
# (отредактировано 3 года, 1 месяц назад) |
Темы: 3 Сообщения: 151 Участник с: 15 сентября 2016 |
|
vs220 |
# |
Темы: 22 Сообщения: 8090 Участник с: 16 августа 2009 |
Форум форматирует невидно ничего такого.
Должно показать проблемные символы |
Slav164 |
# |
Темы: 3 Сообщения: 151 Участник с: 15 сентября 2016 |
|
vs220 |
# (отредактировано 3 года, 1 месяц назад) |
Темы: 22 Сообщения: 8090 Участник с: 16 августа 2009 |
Вот у вас в начале проблемный символ. Пробел скорее всего |
vasek |
# (отредактировано 3 года, 1 месяц назад) |
Темы: 47 Сообщения: 11417 Участник с: 17 февраля 2013 |
vs220 уже подметил про символ Ошибки не исчезают с опытом — они просто умнеют |
Slav164 |
# (отредактировано 3 года, 1 месяц назад) |
Темы: 3 Сообщения: 151 Участник с: 15 сентября 2016 |
Спасибо всё исправил и ошибка исчезла ,но мне интересно откуда эти му могли появиться. |
vs220 |
# |
Темы: 22 Сообщения: 8090 Участник с: 16 августа 2009 |
Перевода строки нет или опять форум чудит? |
vs220 |
# |
Темы: 22 Сообщения: 8090 Участник с: 16 августа 2009 |
А вы фстаб как редактировали? Вообще то при обновлении если конфиг изменялся то он не переписывается а добавляется patcnev, так что скорее всегосами ошиблись или редактор чудит |