PCLinuxOS-Forums
News: ...FLASH!!! ...New PCLinuxOS Testing board now open. Register today! Be an active contributor to the PCLinuxOS future! ... Read all about it now, on THIS forum!!!..
 
*
Welcome, Guest. Please login or register. May 27, 2012, 03:39:57 AM


Login with username, password and session length


Pages: [1]   Go Down
  Print  
Author Topic: Help to enable my new swap partition on boot ?  (Read 487 times)
Cressida
Sr. Member
****
Offline Offline

Posts: 275


« on: November 08, 2010, 02:42:53 PM »

I set up my new HD without a swap partition after reading that it may not be needed when you have plenty of memory.   I'm pretty sure that is what has been causing my start up lock up problems and after I confirm that with more testing after I get a swap partition enabled I will post my experience for others.

For now I have added a swap partition to the new HD.  It is "sda7" and have learned that I need or want to enable it at boot time.  So I read that I need to edit /etc/fstab  to include something like one of these:

/dev/sda7      swap       swap    defaults        0 0

/dev/sda7   none    swap    sw   0 0

However this info is from other distribution comments so I don't know which to use for PCL, or if it should even be slightly different.  

Would one of you power users help me with the terminal commands so that I can get this new swap partition enabled correctly at boot ?    I feel like I'm getting close but since I didn't even have any luck with finding the /etc directory from using the terminal I'm not there yet.

I have tried to use the PCL control center but the new partition still does not show up at all there even though it shows using fdisk -l .   

Using "fdisk -l" the new swap partition is at the end of my HD as follows:

Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        2550    20482843+  83  Linux
/dev/sda2            5101        7649    20474842+  83  Linux
/dev/sda3            7650       48642   329270272    5  Extended
/dev/sda5            7651       14660    56307825   83  Linux
/dev/sda6           21036       30214    73730286   83  Linux
/dev/sda7           48577       48642      524288   82  Linux swap / Solaris
Logged

AMD Athlon 64 3200, 3GB ram,  ~320 GB HD,  Video=ATI Radeon X300 SE (128mb) PCI-e
KDE 4.6?    Kern  2.6.38.8a64

I used to think I knew a lot about computers until I started using Linux.  Now I feel my age...
Was_Just19
Hero Member
*****
Offline Offline

Posts: 6885


MLU


« Reply #1 on: November 08, 2010, 04:56:32 PM »

Go into PCC (configure your computer) - Local Disks - Manage Disk partitions   and there select the Swap partition, and then select to mount it.

Be sure to select Done (bottom right corner) ......  the fstab should be written with the correct entry.
Logged
Cressida
Sr. Member
****
Offline Offline

Posts: 275


« Reply #2 on: November 08, 2010, 06:19:08 PM »

I'd already tried using PCC (configure your computer) several times.  The swap partition did not show up there even though it showed up as expected using fdisk -l as you can see above.    I do not understand why. 

I thought I'd try running from the LiveCD to see what it showed since I'd read somewhere you couldn't do something or make the necessary changes if you were using the HD.  The swap partition didn't show up using the LiveCD either (it looks just like PCC (configure your computer) screen anyway).   I didn't go any further than the screen of just looking at the HD but now I cannot even boot into the system at all. 

Returning back to running from the Live CD - here is now what "fdisk -l" shows: 

[root@localhost guest]# fdisk -l

Disk /dev/sda: 400.1 GB, 400088457216 bytes
255 heads, 63 sectors/track, 48641 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000082ef

Looks like I may have had another bad day.  The disk partitions are all gone.  I checked it using Gparted and it shows the same thing - just one big blank disk.  I'll just have to start all over again and I've gotten too much time invested with PCL to move on to another distribution.  And, I was just about to get things working pretty well thanks to some helpful post on this forum.  I don't have but a handful of documents that I had changed in the past few weeks while I was basically trying to get this all working.

I didn't get the chance to get all the testing done but for now I am going to say here is what I learned:  You DO NEED a swap partition or file or you are going to run into problems!   I don't care if you have 4GB or more and the system shows it never uses 1/4 of that amount.    For me the problems were lock up on start up after the grub menu loaded. 
Logged

AMD Athlon 64 3200, 3GB ram,  ~320 GB HD,  Video=ATI Radeon X300 SE (128mb) PCI-e
KDE 4.6?    Kern  2.6.38.8a64

I used to think I knew a lot about computers until I started using Linux.  Now I feel my age...
Was_Just19
Hero Member
*****
Offline Offline

Posts: 6885


MLU


« Reply #3 on: November 08, 2010, 06:53:52 PM »

You can recover the partition table using
testdisk
if it is deleted.

If it is deleted then I would ask what could have deleted it?
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM