| Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
|
02-22-2013, 07:24 PM
|
#1
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Rep: 
|
Suspend works only sometimes, Ubuntu 12.04
I'm using a home-assembled Shuttle SH67H3. Ubuntu's working great, except that about half the times I try to Suspend, I get a black screen with an error-type message, followed by a return to the screen I'd been working on. The message goes by very quickly. I've gathered what I could from repeated quick glimpses. There are eight or ten lines, several of which appear to be repeats of the preceding line. Here's what I've managed to copy out:
hub 4-0:1.0 hub port status failed (err = -19)
hub 3-0:1.0 0000:03.00.0 failed to suspend async: error -110
some items failed to suspend
That may not be exact, even of those lines, but it's quite close.
I've always been mystified by hubs and ports, and I certainly don't know what to make of this.
The failures to suspend seem to be independent of whether I have any programs open. I.e., I can sometimes suspend with mail, browser, word processor all open; sometimes I can't suspend even when everything appears to be closed.
The problem has existed since I installed the Ubuntu, a week or so ago; it's not a case of it having worked at first, and then didn't. The trouble is consistently intermittent, as it were.
I'm using Logitech wireless keyboard and touchpad. There's nothing else involved -- no mp3 players charging or anything, no external hard drives, no DVD in the player. There is a Belkin router to which the desktop is wired.
Searching these forums, I learned that graphics cards are often the cause of this sort of glitch. My video card came embedded in the Shuttle motherboard, and I haven't been able to learn any more from Shuttle's site about it. I thought maybe I should install another graphics card, but the fact that the trouble is intermittent makes me think the source of the trouble might be something less tangible.
I'm fairly fresh from life with Windows, quite new to running Linux. My instinct is to press Ctrl+Alt+Del to view the task manager. Is there a way, via GUI, to view processes on Ubuntu? Or is there a way to do it through a terminal that would be simple enough for a newbie? Or am I barking up a wrong tree?
I see that some others have had trouble resuming from Suspend; for what it's worth, I've not had any trouble on that end. When I Suspend successfully, it's never (so far) a problem for me to get back in business.
Help?
Thanks.
|
|
|
|
02-26-2013, 03:16 PM
|
#2
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
It may be related to the amount of swap available too, since suspend and hibernation uses swap, how much RAM and swap do you have?
About the error messages if you search the log files you will find tha, logs are under the folder /var/log/ , would be a good idea to post it here, more we know about the problem more tools we have to fix it.
Quote:
Originally Posted by Kirsten
...My instinct is to press Ctrl+Alt+Del to view the task manager. Is there a way, via GUI, to view processes on Ubuntu? Or is there a way to do it through a terminal that would be simple enough for a newbie? ...
|
There is a way to see the processes running in the terminal, or virtual console, if you can't access the GUI, type ctrl+alt+(F1-F6),
there are programs that can show the processes, like top or ps, a good one is htop, those are text type programs that you run in the terminal.
To install htop type in the terminal:
Code:
sudo apt-get install htop
With htop is possible to see a lot things, kill processes, etc.
With ps is possible to list specific processes, example:
Code:
ps aux | grep firefox
Regards
Last edited by ukiuki; 02-26-2013 at 03:17 PM.
|
|
|
1 members found this post helpful.
|
02-27-2013, 11:00 AM
|
#3
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Original Poster
Rep: 
|
Thanks for responding, ukiuki.
I must expose my ignorance(s). Here goes:
I don't know how to find out how much RAM and swap I have.
I don't know how to search log files. Whistling in the dark, I opened a terminal and typed /var/log/, and got back "bash: /var/log/: Is a directory".
I typed "sudo apt-get install htop", and things happened, and I think htop was installed, but I don't know how to use it. It looks like the next command you showed was for use if I'd installed ps, but I think I haven't, and I don't know how.
Can you tell me how to check RAM and swap, how to search log files, and how to see processes using htop?
Thanks!
|
|
|
|
02-27-2013, 09:23 PM
|
#4
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
Quote:
Originally Posted by Kirsten
Thanks for responding, ukiuki.
I must expose my ignorance(s). Here goes:
I don't know how to find out how much RAM and swap I have.
...
|
You are welcome, nobody born knowing anything, and we all are ignorants about one thing or another, there is no exceptions, nobody know everything. The more we learn, more we realized that we don't know a bit of the universe.
To know about the RAM and swap in the terminal type:
swap is a partition which is part of your hard disk, to see the partitions:
Code:
cat /proc/partitions
or as root:
Quote:
Originally Posted by Kirsten
...I don't know how to search log files. Whistling in the dark, I opened a terminal and typed /var/log/, and got back "bash: /var/log/: Is a directory"...
|
As the retuning message says it is a directory or folder if you like. In the terminal to navigate the directories there is the command cd which can be combined with other symbols to do so, example, to go to /var/log from where you are type:
then the command ls can be used to list what is in there,
to go back to your home directory just typing cd alone will do.
You can also use the graphical file manager to navigate the directories or folders.
To understand better the commands in the terminal there is a built in manual in most GNU/Linux distributions.
Type in the terminal:
(press up and down arrow keys to or pageup/pagedown to navigate and q to close the man(manual))
or
or any other that you want to learn about.
Quote:
Originally Posted by Kirsten
It looks like the next command you showed was for use if I'd installed ps, but I think I haven't, and I don't know how.
|
ps is installed by default in GNU/linux try just to type ps
Quote:
Originally Posted by Kirsten
...I typed "sudo apt-get install htop", and things happened, and I think htop was installed, but I don't know how to use it...
|
Looks like you successfully installed it, in the terminal type htop
Then open another terminal and type:
That will give you a little more understanding and view about GNU/Linux.
Regards
|
|
|
1 members found this post helpful.
|
03-04-2013, 08:11 AM
|
#5
|
|
Member
Registered: Dec 2009
Location: New Jersey, USA
Distribution: Debian Lenny (5.0), Squeeze (6.0), Wheezy (7.0), Sid (unstable)
Posts: 269
Rep:
|
Quote:
Originally Posted by ukiuki
to go to /var/log from where you are type:
then the command ls can be used to list what is in there,
to go back to your home directory just typing cd alone will do.
|
Just a note:
You may have to use sudo/ su - to view this directory. Some distributions are moving to make this directory unreadable to normal users for security reasons.
|
|
|
|
03-04-2013, 04:29 PM
|
#6
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
Quote:
Originally Posted by goumba
Just a note:
You may have to use sudo/su - to view this directory. Some distributions are moving to make this directory unreadable to normal users for security reasons.
|
Not really, in Ubuntu a you can read and copy it but can't edit without root powers inside of /var/log.
Regards
|
|
|
|
03-24-2013, 09:59 AM
|
#7
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Original Poster
Rep: 
|
Heya, Ukiuki, if you're still about. Sorry I've taken so long to acknowledge your help. You've given me a lot of help, and I really appreciate it.
I got kind of overwhelmed (by Linux and life both), and shrank away for a bit, but I'm back, and exploring the paths you offered. I haven't made obvious progress yet, but I'm working on it. I did manage to get this, from cat /proc/partitions:
major minor #blocks name
8 0 976762584 sda
8 1 960099328 sda1
8 2 1 sda2
8 5 16660480 sda5
11 0 1048575 sr0
Which of those is my swap partition? Is it big enough that it's not likely to be causing my Suspend problems?
I'll keep working on the rest, starting with learning to navigate and understand man.
Thank you very much!
Kirsten
|
|
|
|
03-24-2013, 12:10 PM
|
#8
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Original Poster
Rep: 
|
Happy day! I just discovered the Gnome Terminal help. I'd rather given up on F1, since it never has done anything for me in a GUI setting. This new (to me) source will help a lot, since there are a lot of basics unfamiliar to me. For instance, it took me a long time to figure out that to use htop to view processes, all I had to do was type htop. Man gave me a lot of information, but before Gnome Terminal help, I didn't know how to use it.
So now I see loads and loads of processes listed in htop. I've been reading about the columns in man. One of the columns is for State, and every one of the processes is State S (=Sleep), except for htop (R (=Running)). My guess is that the next thing to do is, the next time I can't suspend, come back to htop and see whether I can find something different in that column -- perhaps something still running (besides htop).
Is that clear thinking? Is there anything else I should look for?
Thanks!
Kirsten
|
|
|
|
03-24-2013, 03:21 PM
|
#9
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
Hey there! Im glad to see you are making your way through GNU/Linux system, and yes htop is a great software.
Quote:
Originally Posted by Kirsten
...Is that clear thinking? Is there anything else I should look for?...
|
Yes htop will show all processes running and it is possible to figure out just looking there what is going on.
Lets say a program stop responding and is froze, htop will list the process there and you can terminate it using the hot keys.
Another quick way to get info about a program in the terminal is to type --help after the command, not all programs have it thou. Example:
Htop as you already notice show many things, number of processor cores, amount of memory in use and total, swap, etc.
There are other system monitor programs like top, iotop. A very popular one is conky which will be always present in the background and is customizable. It is part of Ubuntu repositories and fun to play with.
Regards
Last edited by ukiuki; 03-24-2013 at 03:23 PM.
|
|
|
|
03-24-2013, 03:27 PM
|
#10
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
Oh, to install conky type in the terminal:
Code:
sudo apt-get install conky-all
Check the screenshots and you'll see what I mean by customizable!!
Regards
|
|
|
|
03-24-2013, 04:16 PM
|
#11
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Original Poster
Rep: 
|
Heya, ukiuki. Thanks for hanging in here with me!
I think I'll wait to explore conky and the rest until I've learned to make use of htop; else I'll just confuse myself. But thanks, I'll check them out when I've got my more pressing matters resolved.
I just tried unsuccessfully to Suspend, and looked in htop and found that all processes (except htop) are Status S. I'm guessing this means that my failure to Suspend isn't due to unterminated processes. Is that right?
Quote:
Originally Posted by Kirsten
major minor #blocks name
8 0 976762584 sda
8 1 960099328 sda1
8 2 1 sda2
8 5 16660480 sda5
11 0 1048575 sr0
|
Can you tell from that list which is my swap partition, and whether it's likely to be the cause of my frequent inability to Suspend? The trouble seems to be unrelated to whether I have any programs open, and also, for what it's worth, I have seen no pattern based on whether I have opened (and closed) any particular applications since the last restart.
Thanks!
|
|
|
1 members found this post helpful.
|
03-24-2013, 07:04 PM
|
#12
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
It is probably sda5, try also this command in the terminal this one will give a more detailed info about partitions:
Also df command give info about the disk.
Regards
|
|
|
|
03-24-2013, 07:11 PM
|
#13
|
|
LQ Newbie
Registered: Aug 2012
Distribution: Ubuntu
Posts: 14
Original Poster
Rep: 
|
Yes, it does look like sda5 is the swap. sudo says that it's 16660480 blocks. I'm not sure what a block is. Is that big enough not to be causing Suspend problems?
Thanks.
|
|
|
|
03-24-2013, 07:20 PM
|
#14
|
|
Member
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 766
Rep: 
|
Yeah it looks big enough, 16Gb with is probably double or same amount of RAM on your computer, now block is a part of the disk plate, which is divided in sectors, blocks and tracks.
https://en.wikipedia.org/wiki/Cylinder-head-sector
https://en.wikipedia.org/wiki/Disk_sector
Now to track down the source of the problem first place to look is always in the logs which are in /var/log.
Regards
Last edited by ukiuki; 03-24-2013 at 07:24 PM.
|
|
|
|
03-24-2013, 07:29 PM
|
#15
|
|
Senior Member
Registered: Oct 2009
Location: Wroclaw, Poland
Distribution: Kubuntu
Posts: 1,044
|
Look at the logs after unsuccessful suspend, there are often information which process or its pid block suspending. Check "cat /var/log/syslog" or "dmesg" commands.
|
|
|
1 members found this post helpful.
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 08:18 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|