LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 02-17-2015, 12:32 AM   #31
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649

Post output of
Quote:
fdisk -l
cat /etc/fstab
 
Old 02-17-2015, 05:19 PM   #32
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
r@r:~$ sudo fdisk -l
[sudo] password for r:

Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 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: 0x000c84b5

Device Boot Start End Blocks Id System
/dev/sda1 2048 40962047 20480000 83 Linux
/dev/sda2 40962048 296962047 128000000 83 Linux
/dev/sda3 600565760 625141759 12288000 82 Linux swap / Solaris

r@r:~$ cat /etc/fstab
# UNCONFIGURED FSTAB FOR BASE SYSTEM
proc /proc proc defaults 0 0
# /dev/sda1
UUID=88cd6423-3301-4e66-ab8f-434fd625341b / ext4 rw,errors=remount-ro 0 1
# /dev/sda2
UUID=e564b561-c72e-4985-bb60-70bb6994a6e2 /home ext4 rw,errors=remount-ro 0 0
# /dev/sda3
UUID=6d3cbf5b-7189-4c85-a0ba-2bac666515b1 ext4 rw,errors=remount-ro 0 0
r@r:~$

I issued the command swapon /dev/sda3 and it looks like it is a swap file but fstab still shows it as ext4.

r@r:~$ sudo swapon -s
Filename Type Size Used Priority
/dev/sda3 partition 12287996 0 -1
r@r:~$

I am also having problems printing now because of a lack of space in my tmp file.

Why can't I find an fstab file under /etc? I have show hidden files enabled.

Thank you for sticking in there.
 
Old 02-17-2015, 09:29 PM   #33
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
All you have to do is change this UUID
Quote:
UUID=6d3cbf5b-7189-4c85-a0ba-2bac666515b1 ext4 rw,errors=remount-ro 0 0
To this UUID from blkid
Quote:
/dev/sda3: LABEL="Swap" UUID="eef40dc8-1768-450c-bb02-a20a20072a14" TYPE="swap"
Then either reboot or do swapon

Last edited by EDDY1; 02-17-2015 at 09:36 PM.
 
Old 02-17-2015, 09:32 PM   #34
JeremyBoden
Senior Member
 
Registered: Nov 2011
Location: London, UK
Distribution: Debian
Posts: 1,947

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
A swap partition doesn't have a file system - such as ext4.
Try:-
Code:
sudo umount /dev/sda3
sudo mkswap /dev/sda3
sudo swapon /dev/sda3
sudo nano /etc/fstab
That last line is to edit the mount of your swap partition, it should be something like:-
Code:
# /dev/sda3
UUID=b554d17c-7d66-477b-b8a2-1e0233ef1329    swap swap sw 0 0
The common editing operations such as CTRL+O = save are displayed on the bottom of the window.

Note that the UUID might/will(?) get changed - to discover what it has changed to, use
Code:
sudo blkid /dev/sda3
BTW You need root access (or sudo) to edit all files in /etc
 
Old 02-17-2015, 09:35 PM   #35
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
To edit fstab
Quote:
sudo nano /etc/fstab
 
Old 02-18-2015, 01:28 AM   #36
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
I had problems using nano. Now my laptop boots to a login prompt and tells me No directory logging in with home=/. When I try to edit fstab it tells me that I am read only when I try to save it.

When I issue a command like sudo cat /etc/fstab I get a message
sudo: unable to open /var/lib/sudo/r/tty1: No such file or directory and then it proceeds to give me the results of the command.

How can I edit fstab?

Thank you
 
Old 02-18-2015, 03:00 AM   #37
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Try this http://askubuntu.com/questions/17573...-as-read-write
 
Old 02-18-2015, 04:58 PM   #38
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
Back Up

I was able to recover by booting from a usb, mounting sda1, and editing fstab. When I used nano it did not open full screen and I managed to truncate the permissions off somehow. I think I have the wrong UUID for my swap file. I think it changed in all my rebooting. The blkid command probably gave me the correct UUID.

r@r:~$ sudo fdisk -l

Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 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: 0x000c84b5

Device Boot Start End Blocks Id System
/dev/sda1 2048 40962047 20480000 83 Linux
/dev/sda2 40962048 296962047 128000000 83 Linux
/dev/sda3 600565760 625141759 12288000 82 Linux swap / Solaris

r@r:~$ sudo blkid
/dev/sda3: LABEL="Swap" UUID="3a9e3dfd-9add-4d9f-9521-1e1ea6363f97" TYPE="swap"
/dev/sda1: UUID="88cd6423-3301-4e66-ab8f-434fd625341b" TYPE="ext4"
/dev/sda2: UUID="e564b561-c72e-4985-bb60-70bb6994a6e2" TYPE="ext4"

r@r:~$ sudo cat /etc/fstab
/dev/sda1:
UUID=88cd6423-3301-4e66-ab8f-434fd625341b ext4 rw,errors=remount-ro 0 1
/dev/sda2:
UUID=e564b561-c72e-4985-bb60-70bb6994a6e2 /home ext4 rw,errors=remount-ro 0 0
/dev/sda3:
LABEL="Swap" UUID="eef40dc8-1768-450c-bb02-a20a20072a14" TYPE="swap" rw,errors=remount-ro 0 0

r@r:~$
 
Old 02-18-2015, 11:12 PM   #39
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Then if you have that type of problem run blkid, then edit fstab according to output.
 
Old 02-19-2015, 01:18 AM   #40
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
Fstab set to match blkid

I edited fstab to match blkid but still did not seem to have swap file until issuing swapon command.

r@r:~$ sudo blkid
[sudo] password for r:
/dev/sda3: LABEL="Swap" UUID="3a9e3dfd-9add-4d9f-9521-1e1ea6363f97" TYPE="swap"
/dev/sda1: UUID="88cd6423-3301-4e66-ab8f-434fd625341b" TYPE="ext4"
/dev/sda2: UUID="e564b561-c72e-4985-bb60-70bb6994a6e2" TYPE="ext4"

r@r:~$ sudo cat /etc/fstab
/dev/sda1:
UUID=88cd6423-3301-4e66-ab8f-434fd625341b ext4 rw,errors=remount-ro 0 1
/dev/sda2:
UUID=e564b561-c72e-4985-bb60-70bb6994a6e2 /home ext4 rw,errors=remount-ro 0 0
/dev/sda3:
LABEL="Swap" UUID=3a9e3dfd-9add-4d9f-9521-1e1ea6363f97 TYPE="swap" rw,errors=remount-ro 0 0

r@r:~$ sudo swapon -s
Filename Type Size Used Priority
r@r:~$ sudo swapon /dev/sda3

r@r:~$ sudo swapon -s
Filename Type Size Used Priority
/dev/sda3 partition 12287996 0 -1
r@r:~$

Thank you
 
Old 02-19-2015, 02:08 AM   #41
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Does it maintain swap from reboot?
edit
sda3 in fstab is wrong format, You only needed to replace UUID in fstab not the whole line I marked the UUID in red. That has change though, so put it back in original format & change to new UUID.

Last edited by EDDY1; 02-19-2015 at 02:16 AM.
 
Old 02-19-2015, 12:57 PM   #42
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
Swap file shows up now.

With the changes I made I wan't sure just what fstab should look like so I cloned fstab off a different laptop and updated the UUID's. The swap file shows up now.

r@r:~$ sudo blkid
[sudo] password for r:
/dev/sda3: LABEL="Swap" UUID="3a9e3dfd-9add-4d9f-9521-1e1ea6363f97" TYPE="swap"
/dev/sda1: UUID="88cd6423-3301-4e66-ab8f-434fd625341b" TYPE="ext4"
/dev/sda2: UUID="e564b561-c72e-4985-bb60-70bb6994a6e2" TYPE="ext4"

r@r:~$ sudo swapon -s
Filename Type Size Used Priority
/dev/sda3 partition 12287996 0 -1

r@r:~$ sudo cat /etc/fstab
# UNCONFIGURED FSTAB FOR BASE SYSTEM
proc /proc proc defaults 0 0
# /dev/sda1
UUID=88cd6423-3301-4e66-ab8f-434fd625341b / ext4
rw,errors=remount-ro 0 1
# /dev/sda2
UUID=e564b561-c72e-4985-bb60-70bb6994a6e2 /home ext4
rw,errors=remount-ro 0 0
# /dev/sda3
UUID=3a9e3dfd-9add-4d9f-9521-1e1ea6363f97 swap swap sw
rw,errors=remount-ro 0 0
r@r:~$

r@r:/$ sudo lsblk -f
NAME FSTYPE LABEL MOUNTPOINT
sda
├─sda1 ext4 /
├─sda2 ext4 /home
└─sda3 swap [SWAP]
sr0
r@r:/$
 
Old 02-19-2015, 05:17 PM   #43
JeremyBoden
Senior Member
 
Registered: Nov 2011
Location: London, UK
Distribution: Debian
Posts: 1,947

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
You don't need
Code:
errors=remount-ro
on a swap partition.
If it has errors, there is no point in remounting it as read only.
 
Old 02-19-2015, 05:17 PM   #44
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
Logs filling up

My /var/log file is taking up 15 Gb. 6 Gb of that is my syslog file. Here is a sample of the messages:

Feb 11 20:41:28 r kernel: [556124.707960] mei_me 0000:00:16.0: reset: unexpected enumeration response hbm.
Feb 11 20:41:28 r kernel: [556124.707963] mei_me 0000:00:16.0: unexpected reset: dev_state = RESETTING
Feb 11 20:41:28 r kernel: [556124.707983] mei_me 0000:00:16.0: reset: wrong host start response
Feb 11 20:41:28 r kernel: [556124.707986] mei_me 0000:00:16.0: unexpected reset: dev_state = RESETTING
Feb 11 20:41:28 r kernel: [556124.708008] mei_me 0000:00:16.0: reset: unexpected enumeration response hbm.
Feb 11 20:41:28 r kernel: [556124.708011] mei_me 0000:00:16.0: unexpected reset: dev_state = RESETTING
Feb 11 20:41:28 r kernel: [556124.708031] mei_me 0000:00:16.0: reset: wrong host start response
Feb 11 20:41:28 r kernel: [556124.708034] mei_me 0000:00:16.0: unexpected reset: dev_state = RESETTING

From Googling it I think it is a bug and I am either suppose to blacklist the module mei_me of stop it in the bios.
I will see if I can find out how to blacklist it. I also noticed that the log goes back to the 11th.

How would be the best way to clear the logs?

Thank you
 
Old 02-20-2015, 01:56 AM   #45
rstuff
Member
 
Registered: Jul 2011
Posts: 151

Original Poster
Rep: Reputation: Disabled
I removed the errors=remount-ro from the swap file and restarted.

Thank you
 
  


Reply



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
[SOLVED] No space left on device Aquarius_Girl Linux - Newbie 34 01-13-2018 04:18 PM
No space left on Device Fra123X Linux From Scratch 8 09-30-2013 04:36 AM
LXer: Linux: No space left on device while df command shows lot of free space LXer Syndicated Linux News 0 08-26-2013 02:50 PM
No space left on device even though it has free space? enine Linux - General 8 05-30-2007 04:22 PM
No space left on device clintdavis Linux - Software 2 05-04-2006 10:38 PM

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

All times are GMT -5. The time now is 02:44 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
Open Source Consulting | Domain Registration