LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 02-05-2010, 04:57 PM   #1
noobuser
LQ Newbie
 
Registered: Feb 2010
Posts: 8

Rep: Reputation: 6
raid1 and hibernate


Hi,I'm a new slackware user.
I'm trying to build my mediacenter xbmc with Slack 13.
I've an Amd system with 2 disks configured in raid1.
A / partition as md0, /home partition as md1 and swap as md2
It works everything fine, also suspend to ram (S3) ,but not hibernate(S4).
My problem is that during restart ,the kernel sees the swap partition (md2) "dirty" and starts immediately the background rebuild deleting my suspended image.
What I should do to fix this issue?Is there some kernel parameter to put in lilo.conf?
In lilo.conf I have these parameters:

Code:
boot = /dev/md0                                                                                        
raid-extra-boot=mbr-only                                                                               
compact        # faster, but won't work on all systems.                                                
# Bitmap in BMP format: 640x480x8                                                                      
  bitmap = /boot/slack.bmp                                                                             
# Menu colors (foreground, background, shadow, highlighted                                             
# foreground, highlighted background, highlighted shadow):                                             
bmp-colors = 255,0,255,0,255,0                                                                       
bmp-table = 60,6,1,16                                                                                
   
bmp-timer = 65,27,0,255                                                                               

# Append any additional kernel parameters:
append=" root=/dev/md0 vt.default_utf8=0 resume=/dev/md2"
prompt
timeout = 50
vga = 773
# vga = normal
# ramdisk = 0     # paranoia setting

image = /boot/vmlinuz-2.6.32.7-smp
  root = /dev/md0
  label = 2.6.32.7
  read-only

# Linux bootable partition config ends
If you need any other info ,just ask
Thank you
 
Old 02-06-2010, 09:20 AM   #2
ivandi
Member
 
Registered: Jul 2009
Location: Québec, Canada
Distribution: CRUX, Debian
Posts: 528

Rep: Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866
You do not need to put the swap on raid device. Just add your two swap partitions to fstab and the kernel will use them in parallel.
 
Old 02-07-2010, 04:30 AM   #3
noobuser
LQ Newbie
 
Registered: Feb 2010
Posts: 8

Original Poster
Rep: Reputation: 6
Quote:
Originally Posted by ivandi View Post
You do not need to put the swap on raid device. Just add your two swap partitions to fstab and the kernel will use them in parallel.
You mean that the kernel will write the same data on BOTH the swap partitions?
I don't think.I'm looking for redundancy also on swap.If I hibernate my system on /dev/sda3 and the next time I resume my system,/dev/sda is dead,I'll lost my system image.

I've found the way anyway,using initrd.The only problem is that the resume is very slow.Probably there is still some recovery of /dev/md2 during resuming.Slackware's initrd script doesn't manage the md_mod.start_ro parameter.
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=415441

I need to understand how to add that option.
 
Old 02-07-2010, 11:46 AM   #4
ivandi
Member
 
Registered: Jul 2009
Location: Québec, Canada
Distribution: CRUX, Debian
Posts: 528

Rep: Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866Reputation: 866
Never tried it myself but may be you should use a swap-file.

filefrag -v /swapfile should return the resume_offset (step 2).
 
Old 02-09-2010, 07:04 AM   #5
noobuser
LQ Newbie
 
Registered: Feb 2010
Posts: 8

Original Poster
Rep: Reputation: 6
Quote:
Originally Posted by ivandi View Post
Never tried it myself but may be you should use a swap-file.

filefrag -v /swapfile should return the resume_offset (step 2).
Thanks for the hint.
I've tried,but I have some problem to manage correctly the resume paramters for the kernel.I think that initrd script doesn't manage correctly the parameters for swap over file.Infact the system at boot time fails looking for the swap file (UUID device not found),but I could be wrong.

Anyway now I'm able to resume correctly from swap device on partition /dev/md2,adding the parameter
Code:
echo 1 > /sys/module/md_mod/parameters/start_ro
in /init script of initrd image.The only problem is that it's really slow,more slow than cold boot.On a single disk configuration (no raid then) it works fine.
Do you have some idea about this problem?
 
  


Reply

Tags
hibernate, raid1


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
Hibernate Ace Blackwell Linux - Hardware 1 08-24-2008 04:34 PM
Have software raid1, but like to change to raid1+0 or 0+1, how? spaceuser Debian 8 03-17-2008 02:07 PM
cli hibernate works but gnome panel hibernate fails BCarey Linux - Desktop 1 06-08-2007 10:21 AM
Cant hibernate 9.3 alaios SUSE / openSUSE 20 08-18-2005 12:08 PM
Can I Hibernate? ernesto_cgf Linux - Software 3 12-23-2004 02:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:36 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