Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
howto: get swsusp2 (hibernate, suspend to disk) working
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3 ... 10, 11, 12, 13, 14  Next  
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
drakos7
Apprentice
Apprentice


Joined: 21 Feb 2003
Posts: 294
Location: Rockville, MD, USA, Earth, Sol

PostPosted: Thu Jan 13, 2005 5:38 pm    Post subject: Reply with quote

Trying to patch gentoo-dev-sources-2.6.10-r4 and no luck. Tried:
. software-suspend-2.1.5-for-2.6.9 (gets a little farther than...)
. software-suspend-2.1.5.10-for-2.6.10
. software-suspend-2.1.5.11-for-2.6.10
. software-suspend-2.1.5.12-for-2.6.10
Back to top
View user's profile Send private message
jphelps
n00b
n00b


Joined: 06 Nov 2004
Posts: 21

PostPosted: Mon Jan 17, 2005 4:25 am    Post subject: Reply with quote

On my system this appears to be to the presence of the bootspash/splash-util stuff in the kernel sources for gentoo-2.6.10-r4. It's impacting the following patches in the software-suspend-2.1.5.14-for-2.6.10 tarball.

100-kdb-v4.4-2.6.10-common-1 will not apply cleanly
130-bootsplash-3.1.4-2.6.10.diff will not apply cleanly
911-single-get_cmos_time-call will not apply cleanly
913-add-__get_cmos_time-quick-call will not apply cleanly
950-check-mounts will not apply cleanly
951-proc-changes-and-try-XX-renames will not apply cleanly
953-page-to-pfn will not apply cleanly
955-readahead will not apply cleanly
957-move-plugin-init-call will not apply cleanly
961-optional-check-mounts will not apply cleanly
993-Checksumming-warning will not apply cleanly
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Mon Jan 17, 2005 5:10 am    Post subject: Reply with quote

I couldn't even get 2.1.5.14 to patch against vanilla 2.6.10..! :?
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Mon Jan 17, 2005 11:40 am    Post subject: Reply with quote

taskara wrote:
I couldn't even get 2.1.5.14 to patch against vanilla 2.6.10..! :?

2.1.5.12 patched flawlessly against vanilla and is working good here so far.
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Mon Jan 17, 2005 11:52 am    Post subject: Reply with quote

ok I'll give r12 a go..

also anyone have an issue whereby when they resume a suspend, X is not displayed properly, so you have to switch to another terminal and back to get it to work?

this is on a centrino laptop i810 Xorg driver
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
blueSceaDa
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2005
Posts: 90

PostPosted: Sun Jan 23, 2005 11:51 am    Post subject: Reply with quote

Hi I hope it's ok if i ask here..
i followed all the instructions at http://gentoo-wiki.com/HOWTO_Software_Suspend_v2 but "hibernate" always tells me there is an error which i can find in dmesg, in dmesg there is:
Code:
Software Suspend 2.1.5.14: Software suspend is disabled.
This may be because you haven't put something along the lines of

resume2=swap:/dev/hda1

in lilo.conf or equivalent. (Where /dev/hda1 is your swap partition


Where else do I need to put it, than in lilo's append line for my kernel and in the hibernate.conf ?

Thanks for any help !
_________________
Athlon XP 2500+ @ ~2100MHz; GeForce FX 5600 256MB; 3x256MB RAM; ASUS A7N8X-X
echo 'LDFLAGS="-Wl,-O1"' >> /etc/make.conf - no problems here
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Sun Jan 23, 2005 12:21 pm    Post subject: Reply with quote

blueSceaDa wrote:
Hi I hope it's ok if i ask here..
It's absolutely ok, that's what this thread is for.
Quote:
"hibernate" always tells me there is an error which i can find in dmesg, in dmesg there is:
Code:
Software Suspend 2.1.5.14: Software suspend is disabled.
This may be because you haven't put something along the lines of

resume2=swap:/dev/hda1

in lilo.conf or equivalent. (Where /dev/hda1 is your swap partition
Did you run lilo after making the change? Could you post your /etc/lilo.conf? Are you sure what you defined there actually is your swap partition (maybe take a look at /etc/fstab and the output of cfdisk and look for your swap partition)?
Back to top
View user's profile Send private message
blueSceaDa
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2005
Posts: 90

PostPosted: Sun Jan 23, 2005 1:29 pm    Post subject: Reply with quote

Yes I reran lilo, i'm also 100% sure it is my swap partition ...

Code:
lba32
boot = /dev/hda
map = /boot/current.map
#    boot-text.b
#    boot-menu.b
#    boot-bmp.b
install = /boot/boot-menu.b
menu-scheme=Wb
prompt
timeout=100
delay = 50
vga = normal
#vga = 791
default = Gentoo-SWS

image = /boot/k2610sws
   vga=791
   root = /dev/hda4
   #root = /devices/discs/disc0/part3
   label = Gentoo-SWS
   read-only # read-only for checking
   append = "resume2=swap:/dev/hda3 video=vesafb:ywrap,mtrr devfs=nomount gentoo=nodevfs"
[...]

_________________
Athlon XP 2500+ @ ~2100MHz; GeForce FX 5600 256MB; 3x256MB RAM; ASUS A7N8X-X
echo 'LDFLAGS="-Wl,-O1"' >> /etc/make.conf - no problems here
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Sun Jan 23, 2005 10:04 pm    Post subject: Reply with quote

it says it "MAY BE because you forgot that line" the problem's not neccessary there ;)

what options did you select in your kernel? could you post your .config? (just the power management section)
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
blueSceaDa
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2005
Posts: 90

PostPosted: Mon Jan 24, 2005 3:46 pm    Post subject: Reply with quote

i have these (left out the unset stuff)
Code:

CONFIG_PM=y
CONFIG_SOFTWARE_SUSPEND2=y
CONFIG_SOFTWARE_SUSPEND2_BUILTIN=y
CONFIG_SOFTWARE_SUSPEND_SWAPWRITER=y
CONFIG_SOFTWARE_SUSPEND_LZF_COMPRESSION=y
CONFIG_SOFTWARE_SUSPEND_TEXT_MODE=y
CONFIG_SOFTWARE_SUSPEND_DEFAULT_RESUME2="/dev/hda3"
CONFIG_SOFTWARE_SUSPEND_CHECK_RESUME_SAFE=y


//edit: sry forgot acpi stuff:
Code:

CONFIG_ACPI=y
CONFIG_ACPI_BOOT=y
CONFIG_ACPI_INTERPRETER=y
CONFIG_ACPI_AC=y
CONFIG_ACPI_BATTERY=y
CONFIG_ACPI_BUTTON=y
CONFIG_ACPI_FAN=m
CONFIG_ACPI_PROCESSOR=m
CONFIG_ACPI_THERMAL=m
CONFIG_ACPI_BLACKLIST_YEAR=0
CONFIG_ACPI_BUS=y
CONFIG_ACPI_EC=y
CONFIG_ACPI_POWER=y
CONFIG_ACPI_PCI=y
CONFIG_ACPI_SYSTEM=y

_________________
Athlon XP 2500+ @ ~2100MHz; GeForce FX 5600 256MB; 3x256MB RAM; ASUS A7N8X-X
echo 'LDFLAGS="-Wl,-O1"' >> /etc/make.conf - no problems here
Back to top
View user's profile Send private message
the_g_cat
Tux's lil' helper
Tux's lil' helper


Joined: 31 Mar 2004
Posts: 117
Location: Dortmund - Germany

PostPosted: Mon Jan 24, 2005 10:24 pm    Post subject: Reply with quote

Hiho,

I would have 2 questions myself, concerning the nvidia driver and S3 suspend (aka suspend-to-ram), cause I can't get any of them to work correctly. My actual working hibernate.conf looks like this:
Code:
UseSwsusp2 yes
Reboot no
EnableEscape yes
DefaultConsoleLevel 1
PowerdownMethod 4

Verbosity 0
LogFile /var/log/hibernate.log
LogVerbosity 1
Distribution gentoo

SaveClock yes

UnmountFSTypes nfs

OnSuspend 20 echo "Good night!"
OnResume 20 echo "Good morning!"

UnloadModules snd_intel8x0
UnloadBlacklistedModules yes
LoadModules auto

GentooModulesAutoload yes

DownInterfaces eth0
UpInterfaces auto

RestartServices xdm

OnResume 21 /etc/init.d/alsasound restart
OnResume 21 /mynfsmounts/tobe/remounted


Yes, I realize restarting alsasound on resume isn't nearly as neat as it would be putting it in RestartServices, but if I do, alsasound won't load correctly on resume.
Concerning the nvidia driver: as you can see, I had to put xdm in the RestartServices, because my screen goes to stand-by after resuming with nvidia still enabled, even though I now use nvagp. Would anyone have a good tip for that ?
Second problem: I have an NF7-S Rev.2.0 (nf2 400), but it won't suspend to ram. If I set PowerdownMethod to 3, it just powers down, and boots up again right from the beginning, and eventually reloads the kernel, and seems to be stuck there. I once caught a glimpse at what I thought was some error just before powering down, but I can't find an sign of it in the log. Would be very nice to get that to work too :D

EDIT: well, the pc gets resumed normally after a 'faulty' S3, but that doesn't make the S3 very useful...
EDIT²: there it gets complicated. I have an option called "Suspend type" (or something alike) in the BIOS, which I can put tu S1 or S3. When it is on S1, going to S3 with hibernate behaves like going to S4, whereas if this option is on S3, the computer will turn on without any sign of a BIOS or something alike (that's what it should be), but the screen remains on standbye and the computer shuts down quiet rapidly after that (that's not what we want). Gonna try it without acpid (which I don't use anyway :D )
EDIT^3: So now with this BIOS option on S3 and hibernate being configured for S3 and with acpid disabled, I can wake from an S3, but the screen won't work, at least the computer stays on (*shrugs* should have tried to ssh on that box at this time)


Last edited by the_g_cat on Mon Jan 24, 2005 11:15 pm; edited 2 times in total
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Mon Jan 24, 2005 10:41 pm    Post subject: Reply with quote

blueSceaDa

your kernel config looks good - however reading the swsp howto it tells me that the command should go on the KERNEL line under lilo (I haven't used lilo for years):

Quote:
You must set the resume kernel option to the swap partition you want to use for suspension. If your partition is, for instance, the third primary one on first ide disk (/dev/hda3) you have to append "resume2=swap:/dev/hda3" as a kernel parameter in your lilo.conf file.


so I think you should try something like this:

Code:
image = /boot/k2610sws resume2=swap:/dev/hda3
   vga=791
   root = /dev/hda4
   #root = /devices/discs/disc0/part3
   label = Gentoo-SWS
   read-only # read-only for checking
   append = "video=vesafb:ywrap,mtrr devfs=nomount gentoo=nodevfs"
[...]

_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Tue Jan 25, 2005 2:58 am    Post subject: Reply with quote

taskara wrote:
Quote:
append "resume2=swap:/dev/hda3" as a kernel parameter in your lilo.conf file.

Isn't this just what the lilo 'append="..."' thingy should do?

But I don't know either, I've been using grub forever...
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Tue Jan 25, 2005 3:58 am    Post subject: Reply with quote

tuxlover wrote:
taskara wrote:
Quote:
append "resume2=swap:/dev/hda3" as a kernel parameter in your lilo.conf file.

Isn't this just what the lilo 'append="..."' thingy should do?

But I don't know either, I've been using grub forever...


*should* ;) but all I know is that it's not working, it's complaining that the line does not exist, and the howto says to add it to the kernel line.. so I could be wrong, but it's prob worth a shot ;)
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
blueSceaDa
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2005
Posts: 90

PostPosted: Tue Jan 25, 2005 2:56 pm    Post subject: Reply with quote

@the_g_cat
thanks to you ! the config you posted made clear to me that i have to comment out some stuff i did not ... "EnableEscape yes" and "DefaultConsoleLevel 1" ... it now works with console, but didnt try with X
_________________
Athlon XP 2500+ @ ~2100MHz; GeForce FX 5600 256MB; 3x256MB RAM; ASUS A7N8X-X
echo 'LDFLAGS="-Wl,-O1"' >> /etc/make.conf - no problems here
Back to top
View user's profile Send private message
the_g_cat
Tux's lil' helper
Tux's lil' helper


Joined: 31 Mar 2004
Posts: 117
Location: Dortmund - Germany

PostPosted: Tue Jan 25, 2005 3:11 pm    Post subject: Reply with quote

blueSceaDa wrote:
@the_g_cat
thanks to you ! the config you posted made clear to me that i have to comment out some stuff i did not ... "EnableEscape yes" and "DefaultConsoleLevel 1" ... it now works with console, but didnt try with X


You're wellcome, but I only took the default hibernate.conf, read some how-to's and the comments, and it works (for console at least) :lol:
Back to top
View user's profile Send private message
blueSceaDa
Tux's lil' helper
Tux's lil' helper


Joined: 05 Jan 2005
Posts: 90

PostPosted: Tue Jan 25, 2005 3:34 pm    Post subject: Reply with quote

i just read the howto at the gentoo-wiki and used hibernate from portage :?
anyway it works now :D
and i used the append="resume2=swap:/dev/hda3" from lilo ... not:

"image = /boot/k2610sws resume2=swap:/dev/hda3" ... lilo reports a error then !
_________________
Athlon XP 2500+ @ ~2100MHz; GeForce FX 5600 256MB; 3x256MB RAM; ASUS A7N8X-X
echo 'LDFLAGS="-Wl,-O1"' >> /etc/make.conf - no problems here
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Tue Jan 25, 2005 10:18 pm    Post subject: Reply with quote

cool :)
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
falconn
Tux's lil' helper
Tux's lil' helper


Joined: 26 Nov 2004
Posts: 89

PostPosted: Wed Jan 26, 2005 2:11 pm    Post subject: Reply with quote

Hi all,

I've a problem with Software suspend with my 2.6.9 kernel from kernel.org. I've no error message when I applied the patches but at boot time all modules can't be loaded (Invalid module format...).
Do you know what is wrong?
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Wed Jan 26, 2005 2:37 pm    Post subject: Reply with quote

Sounds like a kernel compilation/installation issue. Make sure /usr/src/linux is a softlink pointing to the right kernel source directory before building the kernel.

Maybe also post the outputs of

ls -l /usr/src/
ls -l /lib/modules
uname -a

here.
Back to top
View user's profile Send private message
taskara
Advocate
Advocate


Joined: 10 Apr 2002
Posts: 3763
Location: Australia

PostPosted: Wed Jan 26, 2005 10:08 pm    Post subject: Reply with quote

and or build them directly into the kernel, rather than modules, but I agree with tuxlover - you should fix the problem anyway
_________________
Kororaa install method - have Gentoo up and running quickly and easily, fully automated with an installer!
Back to top
View user's profile Send private message
UnknownOrigin
n00b
n00b


Joined: 20 Dec 2004
Posts: 32

PostPosted: Wed Jan 26, 2005 11:52 pm    Post subject: Reply with quote

Where can I find a kernel patch for 2.6.10-r6? The ones at http://developer.berlios.de/project/showfiles.php?group_id=1412 do not work.
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Thu Jan 27, 2005 12:10 am    Post subject: Reply with quote

You have a gentoo specific kernel source tree (gentoo-dev-sources) installed. The swsusp people will not release a patch for it. Either
a) change the official swsusp patch to match your kernel source (often pretty easy) or
b) install a different (official, i.e. vanilla) kernel version, like development-sources-2.6.10.

The gentoo-dev-sources contain additional patches to vanilla, many of which you really don't need (e.g. ones not applying to your platform). You can also choose which patches (out of those) to apply, easily. Just ask.
Back to top
View user's profile Send private message
jakob42
n00b
n00b


Joined: 29 Jan 2005
Posts: 4
Location: Europe - Germany

PostPosted: Sat Jan 29, 2005 7:11 am    Post subject: Reply with quote

tuxlover wrote:
You have a gentoo specific kernel source tree (gentoo-dev-sources) installed. The swsusp people will not release a patch for it. Either
a) change the official swsusp patch to match your kernel source (often pretty easy) or


Hm, im familiar with building kernels and applying patches, but I never altered a patch...

tuxlover wrote:

b) install a different (official, i.e. vanilla) kernel version, like development-sources-2.6.10.

The gentoo-dev-sources contain additional patches to vanilla, many of which you really don't need (e.g. ones not applying to your platform). You can also choose which patches (out of those) to apply, easily. Just ask.


Yeah, I would do that. How do I select the patches I want in gentoo-dev-sources?
TIA
Back to top
View user's profile Send private message
tuxlover
Apprentice
Apprentice


Joined: 21 Oct 2003
Posts: 297
Location: weltweit

PostPosted: Sat Jan 29, 2005 11:36 am    Post subject: Reply with quote

jakob42 wrote:
Hm, im familiar with building kernels and applying patches, but I never altered a patch...
It's often only a couple of lines that got shuffled around in the source, or some spaces that got introduced... sometimes it's also easy to manually apply the changes the patch would apply.
Quote:
Yeah, I would do that. How do I select the patches I want in gentoo-dev-sources?

gentoo-dev-sources is really just 3 packages (downloaded to /usr/portage/distfiles):
    the actual kernel (vanilla), like linux-2.6.10.tar.bz2
    the gentoo patchset (base package), like genpatches-base-2.6-10.07.tar.bz2
    the gentoo patchset (extras. package), like genpatches-extras-2.6-10.07.tar.bz2

Basically you can install the official vanilla source tree with emerge development-sources. After that, emerge but "download only" the gentoo-dev-sources, which gives you the genpatches described above:
Code:
emerge --fetchonly gentoo-dev-sources

Then you can unpack the genpatches to say /usr/src/:
Code:
cd /usr/src/
tar xjf /usr/portage/distfiles/genpatches-2.6-10.07-base.tar.bz2
tar xjf /usr/portage/distfiles/genpatches-2.6-10.07-extras.tar.bz2

As they're only simple patchsets, you can manually apply (or unapply) patches out of those, leaving out the ones you're sure you don't need, just take a look:
Code:
ls genpatches-2.6-10.07
0000_README
1100_drm-dos-fix.patch
1105_capabilities-module-fix.patch
1106_capabilities-module-fix-2.patch
1110_smbfs-dos-fix.patch
1115_sys-uselib-fix-1.patch
1116_sys-uselib-fix-2.patch
1120_moxa-overflow.patch
[...]

You can probably delete the ones you don't want, and then simply apply them from your kernel source tree:
Code:
cd /usr/src/linux
cat /usr/src/genpatches-2.6-10.07/* | patch -p1

(I know you're familiar with doing this but maybe someone else wants to know :) )
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Goto page Previous  1, 2, 3 ... 10, 11, 12, 13, 14  Next
Page 11 of 14

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum