How to re-enable hibernate in ubuntu 12.04

If you’ve just updated to Ubuntu 12.04, you may notice an option missing in its system menu. The Hibernate option is now hidden by default, but you can get it back if you prefer to hibernate your system.

Hibernate is disabled by default because it can cause problems on some system configurations. You should perform a hibernate with a special command to test that it works properly before re-enabling it.

Hibernate vs. Suspend

The Suspend option is still available in Ubuntu’s system menu. Like hibernate, suspend saves your open programs and data, so you can quickly resume to your previous sate. However, suspend requires power — while in suspend mode, your computer will continue to draw a small amount of power. If the system loses power — for example, if you unplug a desktop computer from the power socket or a laptop’s battery empties, you’ll lose your work.

In contras, hibernate saves your system’s state to your hard disk and shuts the system off, consuming no power. When you resume from hibernate, your open programs and data will be restored. Hibernate saves power, but it takes longer – the computer has to restore data to the RAM, while suspend preserves the data in the RAM.

Why It’s Disabled

Hibernate doesn’t work properly on many hardware configurations with Ubuntu and other Linux distributions. If hibernate doesn’t work properly on your system, you may resume from hibernate to find that your work has been lost. Some hardware drivers may also not work properly with hibernate — for example, Wi-Fi hardware or other devices may not work after resuming from hibernate.

To prevent new users from encountering these bugs and losing their work, hibernate is disabled by default.

Testing Hibernate

Before re-enabling hibernate, you should test it to verify it works properly on your system. First, save your work in all open programs — you’ll lose it if hibernate doesn’t work properly.

To test hibernate, launch a terminal. Type terminal into the Dash and or use the Ctrl-Alt-T keyboard shortcut.

In the terminal, run the following command:

Your system will shut down. After running the command, turn your system back on — if your open programs reappear, hibernate works properly.

Troubleshooting Hibernate

While hardware incompatibilities are a major problem with hibernate, there’s one other common problem. Hibernate saves the contents of your RAM to your swap partition. Therefore, your swap partition must be at least as large as your RAM. If you have a 2GB swap partition and 4GB of RAM, hibernate won’t work properly.

A quick way to compare your RAM and swap sizes is with the System Monitor application.

You can view the memory and swap sizes on the Resources tab. “Memory” here refers to your RAM.

If really want to use hibernate and your swap partition is smaller than your RAM, try running GParted from a live CD. You can run GParted from a Ubuntu live CD or a dedicated GParted live CD. From the live CD, you can resize your Ubuntu partitions — you can’t do this while they’re in-use.

Re-Enabling Hibernate

You can run the sudo pm-hibernate command whenever you want to hibernate, but this is inconvenient. To re-enable the hibernate option in the menus, you’ll have to create a PolicyKit file.

You can use any text editor for this, but we’ll use gedit in this example. Run the following command to launch gedit as the root user and specify the file you want to create:

gksu gedit /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

Paste the following text into the file:

[Enable Hibernate]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes

Save the text file, then log out and log back in. You’ll be able to hibernate from the system menu.

Chris Hoffman
How to re-enable hibernate in ubuntu 12.04Chris Hoffman
Editor-in-Chief

Chris Hoffman is Editor-in-Chief of How-To Geek. He’s written about technology for over a decade and was a PCWorld columnist for two years. Chris has written for The New York Times, been interviewed as a technology expert on TV stations like Miami’s NBC 6, and had his work covered by news outlets like the BBC. Since 2011, Chris has written over 2,000 articles that have been read nearly one billion times—and that’s just here at How-To Geek. Read more.

How to re-enable hibernate in ubuntu 12.04

If you’ve just updated to Ubuntu 12.04, you may notice an option missing in its system menu. The Hibernate option is now hidden by default, but you can get it back if you prefer to hibernate your system.

Hibernate is disabled by default because it can cause problems on some system configurations. You should perform a hibernate with a special command to test that it works properly before re-enabling it.

Hibernate vs. Suspend

The Suspend option is still available in Ubuntu’s system menu. Like hibernate, suspend saves your open programs and data, so you can quickly resume to your previous sate. However, suspend requires power — while in suspend mode, your computer will continue to draw a small amount of power. If the system loses power — for example, if you unplug a desktop computer from the power socket or a laptop’s battery empties, you’ll lose your work.

How to re-enable hibernate in ubuntu 12.04

In contras, hibernate saves your system’s state to your hard disk and shuts the system off, consuming no power. When you resume from hibernate, your open programs and data will be restored. Hibernate saves power, but it takes longer – the computer has to restore data to the RAM, while suspend preserves the data in the RAM.

Why It’s Disabled

Hibernate doesn’t work properly on many hardware configurations with Ubuntu and other Linux distributions. If hibernate doesn’t work properly on your system, you may resume from hibernate to find that your work has been lost. Some hardware drivers may also not work properly with hibernate — for example, Wi-Fi hardware or other devices may not work after resuming from hibernate.

To prevent new users from encountering these bugs and losing their work, hibernate is disabled by default.

Testing Hibernate

Before re-enabling hibernate, you should test it to verify it works properly on your system. First, save your work in all open programs — you’ll lose it if hibernate doesn’t work properly.

To test hibernate, launch a terminal. Type terminal into the Dash and or use the Ctrl-Alt-T keyboard shortcut.

How to re-enable hibernate in ubuntu 12.04

In the terminal, run the following command:

How to re-enable hibernate in ubuntu 12.04

Your system will shut down. After running the command, turn your system back on — if your open programs reappear, hibernate works properly.

Troubleshooting Hibernate

While hardware incompatibilities are a major problem with hibernate, there’s one other common problem. Hibernate saves the contents of your RAM to your swap partition. Therefore, your swap partition must be at least as large as your RAM. If you have a 2GB swap partition and 4GB of RAM, hibernate won’t work properly.

A quick way to compare your RAM and swap sizes is with the System Monitor application.

How to re-enable hibernate in ubuntu 12.04

You can view the memory and swap sizes on the Resources tab. “Memory” here refers to your RAM.

How to re-enable hibernate in ubuntu 12.04

If really want to use hibernate and your swap partition is smaller than your RAM, try running GParted from a live CD. You can run GParted from a Ubuntu live CD or a dedicated GParted live CD. From the live CD, you can resize your Ubuntu partitions — you can’t do this while they’re in-use.

Re-Enabling Hibernate

You can run the sudo pm-hibernate command whenever you want to hibernate, but this is inconvenient. To re-enable the hibernate option in the menus, you’ll have to create a PolicyKit file.

You can use any text editor for this, but we’ll use gedit in this example. Run the following command to launch gedit as the root user and specify the file you want to create:

gksu gedit /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

How to re-enable hibernate in ubuntu 12.04

Paste the following text into the file:

[Enable Hibernate]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes

How to re-enable hibernate in ubuntu 12.04

Save the text file, then log out and log back in. You’ll be able to hibernate from the system menu.

  • › How to Show Your Work Hours and Location in Google Calendar
  • › You Can Finally Move WhatsApp Chats From iPhone to Android
  • › How to Print Double-Sided on Windows 11
  • › Samsung Galaxy Phones Are Getting Grammarly Installed by Default
  • › How to Enable Cookies in Google Chrome

How to re-enable hibernate in ubuntu 12.04 Chris Hoffman
Chris Hoffman is Editor-in-Chief of How-To Geek. He’s written about technology for over a decade and was a PCWorld columnist for two years. Chris has written for The New York Times, been interviewed as a technology expert on TV stations like Miami’s NBC 6, and had his work covered by news outlets like the BBC. Since 2011, Chris has written over 2,000 articles that have been read nearly one billion times—and that’s just here at How-To Geek.
Read Full Bio »

How to re-enable hibernate in ubuntu 12.04

If you like continuing your work from where you left off the last time, such as when using multiple workspaces or regularly using the same applications to perform the same tasks arranged in a similar fashion, you would probably like your computer to remember how everything was arranged when you switched it off.

Of course, there is a special state called “hibernation” to allow for just that, but if you are an Ubuntu user you may have noticed that hibernation is no longer an option. Unfortunately, the standard hibernation that would save your computer’s state to disk before shutting down the system then reload it upon boot, was disabled in Ubuntu 12.04 and beyond for being buggy and unreliable.

If you are using the recent version of Ubuntu, the old dconf trick of turning on org > gnome > gnome-session > auto-save-session will not work either.

How to re-enable hibernate in ubuntu 12.04

Fortunately there is a way to re-enable hibernate in Ubuntu through editing some policykit configurations. So if you are confident in changing your system configurations, just follow the simple tutorial below.

Note: The below modifications have the potential to mess up your system. Please proceed with care and caution and make backups of your important data or even your entire system. Proceed at your own risk. The author is in no way responsible if anything breaks. If you don’t feel confident to troubleshoot a problem, it is best to close this browser window now, have a coffee, and forget about this tutorial at least for the time being.

Checking if hibernation works at all

Before proceeding with permanently changing your system, you should first try to see if you can hibernate it. For this you will need a swap partition that is at least as large as your physical RAM and that will auto-mount at system startup (if you installed Ubuntu with the default options you should probably have it). Save all your work (possibly even make backup if you prefer to be really safe), but leave some windows open. Now open a terminal either from your dash or with the keyboard shortcut “Ctrl + Alt + T” and type

Your system will shut down. Once it is completely powered off, turn it on and see if your last session was restored. If it worked, you can safely proceed; hibernation will work as expected. If your session did not restore, or if you encounter errors, that can be for a number of reasons, and unless you can iron it out, it is best not to proceed with the below modifications.

Re-enabling Hibernate

(MTE has already provided a short tutorial for enabling hibernation in Ubuntu 12.04. Things have changed a little since, so the previous tutorial might not work for the recent version of Ubuntu.)

If you are certain that hibernation will work on your system, you can put the hibernation menu back into where it used to be by creating the file /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla as root with your favourite text editor. With nano you would type:

and insert the following lines:

How to re-enable hibernate in ubuntu 12.04

Ubuntu has switched from upower to logind since 14.04, so the above code should be sufficient. For earlier versions or if the above does not seem to work, you can try:

(Note: this will probably not work for versions below 13.10.)

If you are not sure, or just want to be on the safe side, you can include both versions.

Save the file and either reboot your system or restart the indicator session, with

The “Hibernate” options should now appear as before

How to re-enable hibernate in ubuntu 12.04

Conclusion

Hibernation is a useful feature that would enable you to save your current session and continue working as if uninterrupted. Unfortunately removed by Ubuntu, the option can be easily re-enabled and used for enhanced productivity with the above simple method.

Attila is a writer, blogger and author with a background in IT management. Using GNU/Linux systems both personally and professionally, his advice stems from 10+ years of hands on experience. In his free time he also runs the popular Meditation for Beginners blog.

If you have upgraded to Ubuntu 12.04, you may be wondering what happened to the “Hibernate” option in the power menu.

For those of you who are not aware or don’t use this feature at all, the Hibernate button usually lies above the Shut Down option and I use it a lot on my machines to save the current machine state to the hard drive rather than shut down or suspend. The next time you power up, hibernate restores to the previous saved state without going through the full boot process.

So why is hibernate missing in Ubuntu 12.04?”

Apparently Ubuntu’s Hibernate feature has not worked consistently on all computers, particularly new hardware models, where, some instances, the Hibernate feature has even caused data loss. So Canonical put out a statement to the effect:

“For Ubuntu to present a Suspend function that doesn’t work is unprofessional, and presenting a Hibernate function that doesn’t work (and destroys data by never waking up) is even worse.”


“After much discussion and debating, the final decision is to disable Hibernate by default on all computers, unless the computer is on a whitelist. The whitelist will include all “Ubuntu Certified” computers that have been tested and proven to work with the Hibernate feature. So if you are not seeing the Hibernate button, most probably your PC is not “Ubuntu Certified”.

Well, no ####, Sherlock. Sadly those of us who know that it works and want to keep using it now have to resort to the Linux command-line ghetto to re-enable it.

The Hibernate option is still available under “Power -> When power is critically low” system setting, which you can enable without any further action or warning, so you can get your laptop to go into Hibernate mode when your batter power is critically low. But not in regular use.

How to re-enable the Hibernate feature
First, make sure your PC supports the Hibernate feature. Close all open data files, open a terminal and type

sudo pm-hibernate.

If your machine successfully hibernates and you can wake it, then your PC supports the Hibernate feature. You can proceed to restore the Hibernate option for normal use.

In the terminal, use root privileges to open the following policy kit file:

sudo gedit /etc/polkit-1/localauthority/50-local.d/com.ubuntu.desktop.pkla

Search for the section

[Disable hibernate by default]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=no

and replace it with the following:

[Re-enable hibernate by default]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes

If the file is empty (some are), you can simply add this section.

Save the file and exit.

Restart the machine and the Hibernate option should return to the power menu. RC

Jack Wallen’s tips for making Ubuntu 12.04 Precise Pangolin easier to use include instructions on installing Ubuntu Tweak and Ubuntu One Cloud Indicator.

Re-enable hibernate

If you installed Ubuntu Precise Pangolin on a laptop, you probably noticed that hibernate is missing. Out of the box, Ubuntu 12.04 only offers suspend. In some cases, you need hibernate (e.g., when your computer’s battery is critically low and you don’t want to lose your work, or when you don’t have power to save the suspend state). Here are details about the two states:

  • Suspend: This state is like putting the computer to sleep. The computer will remain powered on and all of your work will be left open, but it will use much less power. You can wake the computer by pressing a key or clicking the mouse.
  • Hibernate: This state is basically turning the computer off completely while saving the current state of the computer (such as keeping all of your open documents). When you turn the computer back on from hibernation, all of your work should be restored as it was before hibernation. No power is used during this state.

I have no idea why hibernate was not included in 12.04, but I do know how you can add it to your system. Follow these steps as I describe how to get hibernate back.

Step 1: Create a hibernate file

Open a terminal window and issue the command sudo gedit /var/lib/polkit-1/localauthority/50-local.d/hibernate.pkla. Enter your sudo password to complete the opening of a new file.

Step 2: Add the necessary text

When the Gedit window opens, add the following text:

Save that file and close Gedit.

Step 3: Reboot and configure Reboot the laptop and, once you’re back at your desktop, go to System Settings | Power and enable Hibernate per your requirements (Figure A). Figure A

Click the image to enlarge.

You should be able to enjoy the hibernate option again.

Install Ubuntu Tweak

One tool I used quite a bit prior to Unity was Ubuntu Tweak, which brings most of the configuration options together in one place. To install Ubuntu Tweak, follow these simple steps:

1. Issue the command sudo add-apt-repository ppa:tualatrix/ppa.

2. Type your sudo password and hit Enter.

3. Hit Enter again when prompted.

4. Issue the command sudo apt-get update.

5. Issue the command sudo apt-get install ubuntu-tweak.

6. Open the Unity Dash, type tweak, and open the tool when the icon appears.

Install the Ubuntu One Cloud Indicator

I am a heavy user of Ubuntu One. I like to have quick access to my Ubuntu One files and account, and thankfully, there’s an easy way to enable that: install the Ubuntu One Cloud Indicator. This interactive icon resides in the notification area where you can:

  • Quickly open the Ubuntu One folder.
  • Launch the Ubuntu One website.
  • Check sync status.
  • Open the Ubuntu One Control Panel.
  • Check Recently published files.
  • Disconnect the machine from the account.

To install this handy tool, issue these commands:

  • sudo add-apt-repository ppa:rye/ubuntuone-extras
  • sudo apt-get update
  • sudo apt-get install indicator-ubuntuone
Left-click the icon to reveal the menu.

Install the Recent Notifications Indicator

One of the many indicators you can add to the notification tray is the Recent Notifications Indicator. To install this, issue the following commands:

  • sudo add-apt-repository ppa:jconti/recent-notifications
  • sudo apt-get update
  • sudo apt-get install indicator-notifications

Once you’ve done that, log out and log back in to reveal the Recent Notifications indicator. If you’re interested in more of the indicators, you can replace “indicator-notifications” above, with any of the following:

  • indicator-weather
  • caffeine
  • indicator-virtualbox
  • classicmenu-indicator
  • cryptfolder-indicator
  • disper-indicator
  • fluxgui
  • google-tasks-indicator
  • indicator-sysmonitor
  • lookit
  • touchpad-indicator
  • indicator-keylock
  • indicator-workspaces
  • pastie

Move the window buttons

Many Ubuntu 12.04 users can’t seem to get used to the Close, Minimize, and Maximize buttons that are in the left corner of the window. To move those buttons back to the right side, you must install the Gconf Editor:

  1. Open a terminal.
  2. Issue the command sudo apt-get install gconf-editor.
  3. Once installed, issue the command gconf-editor.
  4. In the resulting window (Figure C) navigate to apps | metacity | general.
  5. Locate and right-click the button_layout parameter.
  6. Select Edit Key.
  7. In the Value section, change the text to menu:minimize,maximize,close and hit Enter.
  8. Close Gconf Editor.

Figure C

If this tool reminds you of regedit, it should!

Share a tweak or configuration

There are a lot more tweaks and configurations you can tackle with Ubuntu 12.04. If you’ve found a handy or cool tweak for the latest release from Canonical, share it with your fellow TechRepublic readers.

How to re-enable hibernate in ubuntu 12.04

Open Source Weekly Newsletter

You don’t want to miss our tips, tutorials, and commentary on the Linux OS and open source applications. Delivered Tuesdays

If you have upgraded to Ubuntu 12.04, one thing that you will find missing is the “Hibernate” button. For those of you who are not aware or don’t use this feature at all, the Hibernate button usually lies above the Shut Down option and it allows you to save your current state to the hard drive so the next time you boot up, it can restore to the previous saved state without going through the usual boot up loop.

Why Hibernate is disabled by default in Ubuntu 12.04?

Some of you who are used to the Hibernate feature in Ubuntu might be asking “why is this missing in Ubuntu 12.04?

The reason behind this is because Ubuntu’s Hibernate feature has always not been working well in many computers. For new hardware models, the Hibernate feature often don’t work by default. In some instances, the Hibernate feature will even lead to data loss. The rationale behind the removal of the Hibernate button is:

For Ubuntu to present a Suspend function that doesn’t work is unprofessional, and presenting a Hibernate function that doesn’t work (and destroys data by never waking up) is even worse.

After much discussion and debating, the final decision is to disable Hibernate by default on all computers, unless the computer is on a whitelist. The whitelist will include all “Ubuntu Certified” computers that have been tested and proven to work with the Hibernate feature. So if you are not seeing the Hibernate button, most probably your PC is not “Ubuntu Certified”.

Where to access the Hibernate feature?

Currently, the Hibernate feature is only available in the “Power -> When power is critically low” settings. You can get your laptop to go into Hibernate mode when your batter power is critically low.

How to re-enable hibernate in ubuntu 12.04

How to get back the Hibernate feature?

If you are not sure if your PC supports the Hibernate feature, open a terminal and type pm-hibernate . If your PC succeed in going to Hibernate mode and you have no problem waking it up, your PC supports the Hibernate feature. You can then proceed to the next step to restore the Hibernate option.

In the terminal and open the following file:

Add the following:

Save (Ctrl + o) and exit (Ctrl + x).

Restart the PC. The Hibernate option should return now.

Damien Oh started writing tech articles since 2007 and has over 10 years of experience in the tech industry. He is proficient in Windows, Linux, Mac, Android and iOS, and worked as a part time WordPress Developer. He is currently the owner and Editor-in-Chief of Make Tech Easier.

It seems that Canonical always finds a way to annoy users after the release of each new Ubuntu operating system version. And this time around they have done it again by excluded the Hibernate option from the Session Menu in Ubuntu 12.04. Nonetheless, the Hibernate option is easier to enable than you might think, even if it requires some tweaking with a system file. If you would like to re-enable the Hibernate option in Ubuntu 12.04 Precise Pangolin, then follow the instructions given below.

In the first step enter the following command in a Terminal window.

This will open the hibernate.pkla file. Copy and paste the following text in the file and hit save.

Once done, restart your system for the changes to take effect.

This will enable the Hibernate option. You can see the comparison given in the below screenshots, The left-hand side image displays the default session menu, whereas, the left-hand side image shows the session menu after editing the hibernate.pkla file.

While I will admit that it isn’t all that hard to enable the Hibernate option by using the above mentioned method, I must add that such tweaking is the same reason why many people do not use Ubuntu and other Linux distributions or remain reluctant to switch from other operating systems (such as Windows) to Linux. Why such a minor option is not enabled by default or enabling it requires file tweaking is beyond my understanding. What’s worse is that Canonical will probably not learn any lessons from users complaints regarding such common annoyances.

When I upgraded from 11.10 to 12.04 my Ubuntu power menu has lost the ability to hibernate. Is there a way to add that back in, or is this default for 12.04?

How to re-enable hibernate in ubuntu 12.04

6 Answers 6

Unfortunately, hibernation has been disabled by default in Ubuntu 12.04, because it wasn’t working correctly on many systems.

If you are not sure if hibernation works with your hardware, you can test it by sending the hibernate command from your Terminal

Here’s how to enable it anyway: (warning: only for advanced users — might not work)

In the Terminal, type:

sudo gedit /var/lib/polkit-1/localauthority/10-vendor.d/com.ubuntu.desktop.pkla

Enter your password when requested.

Search for the section

[Disable hibernate by default]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=no

and replace it with

[Re-enable hibernate]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes

After the next restart, the option “Hibernate” will be back in the ‘power menu’ at the top right of your screen. If your hardware supports hibernation, it’ll work now.

Note: In case you want to disable hibernation again, just revert the changes made above.

How to re-enable hibernate in ubuntu 12.04

Hibernation is disabled by default in Ubuntu 12.04. A rationale of this decision can be found in this bug report.

See this question to reenable it:

Jorge: there are several ways to hibernate a Linux computer. If Ubuntu’s defaults fail, you can always try the other hibernation systems.

After that, reboot. That will install the uswsusp system, a reliable system with compression, that wasn’t even installed with Precise.

The second system is TuxOnIce, but setting it up requires more technical skills.

After that, follow the Precise howto for enabling hibernation, posted before. It’s sad to see that the packages needed to hibernate aren’t even installed in a Precise default install. If you don’t install “hibernate”, if you try to run “sudo pm-hibernate”, that command won’t do anything (althogh on some systems it would perform a shutdown).

How to re-enable hibernate in ubuntu 12.04

Hvis du lige har opdateret til Ubuntu 12.04, kan du se en mulighed manglende i systemmenuen. Dvaletilstanden er nu gemt som standard, men du kan få det tilbage, hvis du foretrækker at dvale dit system.

Hibernate er deaktiveret som standard, fordi det kan medføre problemer på nogle systemkonfigurationer. Du bør udføre dvaletilstand med en speciel kommando for at teste, at det virker ordentligt, før du genaktiverer det.

Hibernate vs Suspend

Suspend-indstillingen er stadig tilgængelig i Ubuntus systemmenu. Ligesom dvaletilstand sparer oprydning dine åbne programmer og data, så du hurtigt kan genoptage dit tidligere sate. Men suspendering kræver strøm – i suspenderingsmodus fortsætter computeren med at trække en lille smule strøm. Hvis systemet mister strøm – hvis du f.eks. Tager en stikkontakt ud af stikkontakten eller en bærbar computer tømmer, mister du dit arbejde.

How to re-enable hibernate in ubuntu 12.04

Til gengæld sparer dvaletilstand systemets tilstand på din harddisk og slukker for systemet, forbruger ingen strøm. Når du fortsætter fra dvale, vil dine åbne programmer og data blive genoprettet. Hibernate sparer strøm, men det tager længere tid – computeren skal gendanne data til RAM, mens suspendering bevarer dataene i RAM'et.

Hvorfor det er deaktiveret

Dvale fungerer ikke korrekt på mange hardwarekonfigurationer med Ubuntu og andre Linux-distributioner. Hvis dvaletilstand ikke fungerer korrekt på dit system, kan du genoptage dvaletilstand for at finde ud af, at dit arbejde er gået tabt. Nogle hardwaredrivere fungerer muligvis ikke korrekt med dvale – for eksempel fungerer Wi-Fi-hardware eller andre enheder muligvis ikke, når de genoptages fra dvale.

For at forhindre, at nye brugere støder på disse fejl og mister deres arbejde, er dvaletilstanden deaktiveret som standard.

Test af dvaletilstand

Før du aktiverer dvaletilstand igen, skal du teste det for at kontrollere, at det fungerer korrekt på dit system. Først skal du gemme dit arbejde i alle åbne programmer – du vil miste det, hvis dvaletilstand ikke fungerer korrekt.

For at teste dvale skal du starte en terminal. Skriv terminal i Dash og eller brug Ctrl-Alt-T tastaturgenvej.

How to re-enable hibernate in ubuntu 12.04

I terminalen skal du køre følgende kommando:

How to re-enable hibernate in ubuntu 12.04

Dit system lukkes. Når du har kørt kommandoen, skal du tænde for dit system – hvis dine åbne programmer vises igen, går dvaletilstanden ordentligt.

Fejlfinding Hibernate

Mens hardware inkompatibiliteter er et stort problem med dvale, er der et andet almindeligt problem. Hibernate gemmer indholdet af dit RAM til din swap partition. Derfor skal din swap partition være mindst lige så stor som dit RAM. Hvis du har en 2 GB swap partition og 4 GB RAM, vil dvale ikke fungere korrekt.

En hurtig måde at sammenligne dine RAM- og swapstørrelser på er med System Monitor-applikationen.

How to re-enable hibernate in ubuntu 12.04

Du kan se hukommelsen og bytte størrelser på fanen Ressourcer. "Hukommelse" refererer her til dit RAM.

How to re-enable hibernate in ubuntu 12.04

Hvis du virkelig vil bruge dvaletilstand, og din swap-partition er mindre end dit RAM, skal du prøve at køre GParted fra en live-cd. Du kan køre GParted fra en Ubuntu live CD eller en dedikeret GParted live-cd. Fra live-cd'en kan du ændre størrelsen på dine Ubuntu-partitioner – du kan ikke gøre dette, mens de er i brug.

Genaktivere dvaletilstand igen

Du kan køre sudo pm-hibernate kommandoen, når du vil dvale, men det er ubelejligt. For at genaktivere dvaletilstanden i menuerne skal du oprette en PolicyKit-fil.

Du kan bruge en hvilken som helst tekstredigerer til dette, men vi bruger gedit i dette eksempel. Kør følgende kommando for at starte gedit som rodbrugeren og angive den fil, du vil oprette: