You are not logged in.

#1 2013-08-27 17:32:10

jmagnare
Member
Registered: 2013-08-27
Posts: 2

[DIS-SOLVED] Sudo hangs after a few uses

I've been searching around for this for some time, but haven't found any enlightenment yet.

Basically, after rebooting I can use sudo a few times (usually 3) successfully. After that, any sudo command just hangs. Interestingly, "sudo -k" still returns normally, but "sudo -v" hangs. It is worth noting that sudo gets as far as prompting me for my password before hanging.

Background - possibly useful:

I've had arch running for a few months now, and this just started happening yesterday, when I left my machine running overnight doing a large dd to an external drive as described here: https://wiki.archlinux.org/index.php/Di … _hard_disk . I woke up, found that the i/o was all finished (I could tell because I was using pv to monitor it), but the command ( which was "sudo dd if=/dev/sda conv=sync,noerror bs=32M | pv -pbert | gzip -c > /run/media/jimbo/Backup2/sda_82513.img.gz") hadn't returned and wasn't responding to SIGINTs. The hanging behavior started here, and I wasn't able to kill the process or unmount my external cleanly. I'm not sure exactly what I did then, but I'm pretty sure I just hard-rebooted my machine, and I've been seeing this behavior ever since.

Any pointers or advice would be greatly appreciated. I'll post any config files you guys are interested in, with PII redacted.

Last edited by jmagnare (2013-08-30 21:05:05)

Offline

#2 2013-08-29 02:09:09

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,198

Re: [DIS-SOLVED] Sudo hangs after a few uses

Welcome to Arch's forums.

Nothing from /dev/sda was mounted, right? (https://wiki.archlinux.org/index.php/Disk_Cloning#Create_disk_image point 2)

What does pv-pbert do?

Last edited by cfr (2013-08-29 02:09:25)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#3 2013-08-29 17:01:41

jmagnare
Member
Registered: 2013-08-27
Posts: 2

Re: [DIS-SOLVED] Sudo hangs after a few uses

Thanks for the warm welcome! I'm having a blast using arch so far.

So I restored from the dd that I had done, and things are working fine now. I'm not sure what I should do with this thread: should I mark it solved? I didn't actually discover the cause of the problem, so that doesn't seem right.

To answer your questions:
1. I may have had one of the partitions on sda mounted. Is this likely to have caused what I saw?
2. pv, which I just discovered, allows you to see the progress of data through a pipeline. It's pretty neat. The p, b, e, r, and t flags should turn on the progress bar, byte counter, ETA timer, rate counter, and timer, respectively. After looking at the man page, it appears that this is actually the default behavior. So I could have just used pv with no options.

Last edited by jmagnare (2013-08-29 17:03:00)

Offline

#4 2013-08-29 20:35:58

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,198

Re: [DIS-SOLVED] Sudo hangs after a few uses

Maybe you should mark it [dissolved] rather than [solved]?!

Thanks for the info. I realise I misread your original post as using pv-pbert rather than pv -pbert. I've now managed to find the package you were talking about!

EDIT: The reason I asked about mounted partitions was because the wiki article you linked to said that you must make sure no partitions on the source are mounted when creating the image. I don't know what effects it might have if you do have them mounted, though. It just seemed like something to look into as a potential cause.

Last edited by cfr (2013-08-29 20:43:37)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

Board footer

Powered by FluxBB