You are not logged in.

#1 2018-06-20 04:34:54

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Computer freezes up in konsole

Lately for whatever reason my computer has been freezing up when I am in the terminal. I have two partitions, one for my home folder which is sittin on an SSD and a second one for my bulk storage which is my HDD. I have the HDD mounted on

/run/media/user/DATA/ 

and after using the laptop for (we'll say a little while I've not yet noticed what is causing this....) whenever I try doing anything inside the

/run/medai/user/DATA/

folder the terminal will freeze up and be unusable. for example somthing like

cd /run/media/user/DATA (tab to autocomplete)

will leave the terminal hanging or

sudo umount /run/media/user/DATA

does the same, where as something like

ls /etc/netctl/A (tab to autocomplete)

works just fine. I'm not really sure what information would be needed to debug this so please let me know and I will post it! Also whenever trying to access the partion in Dolphin, Dolphin will freeze up as well becoming unusable. (Also not sure if it's important to note but it is independent of the command that I use it is just whenever I attempt to access the bulk partition)


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#2 2018-06-20 04:48:13

Askannz
Member
Registered: 2016-10-22
Posts: 36

Re: Computer freezes up in konsole

Have a look at dmesg messages. Run

dmesg -w

in another terminal and look for anything suspicious when the freeze occurs. Same with

journalctl -f

(systemd logs).

Offline

#3 2018-06-21 02:35:05

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

this is the output of dmesg -w when the freeze happens

[52088.916074] INFO: task bash:17805 blocked for more than 120 seconds.
[52088.916078]       Not tainted 4.14.50-1-lts #1
[52088.916081] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
[52088.916084] bash            D    0 17805      1 0x00000004
[52088.916088] Call Trace:
[52088.916094]  ? __schedule+0x284/0x870
[52088.916101]  ? generic_make_request+0xd1/0x310
[52088.916106]  ? out_of_line_wait_on_atomic_t+0x120/0x120
[52088.916110]  schedule+0x28/0x80
[52088.916116]  io_schedule+0x12/0x40
[52088.916121]  bit_wait_io+0xd/0x50
[52088.916125]  __wait_on_bit+0x6c/0x80
[52088.916131]  out_of_line_wait_on_bit+0x91/0xb0
[52088.916137]  ? bit_waitqueue+0x30/0x30
[52088.916170]  ext4_bread+0x89/0xa0 [ext4]
[52088.916203]  __ext4_read_dirblock+0x2c/0x290 [ext4]
[52088.916230]  htree_dirblock_to_tree+0x69/0x280 [ext4]
[52088.916255]  ext4_htree_fill_tree+0xa0/0x2d0 [ext4]
[52088.916262]  ? kmem_cache_alloc_trace+0xf8/0x190
[52088.916282]  ext4_readdir+0x5bc/0x990 [ext4]
[52088.916290]  iterate_dir+0x82/0x1a0
[52088.916295]  SyS_getdents+0x9b/0x130
[52088.916300]  ? iterate_dir+0x1a0/0x1a0
[52088.916305]  do_syscall_64+0x67/0x100
[52088.916312]  entry_SYSCALL_64_after_hwframe+0x3d/0xa2
[52088.916315] RIP: 0033:0x7f17a273e1d8
[52088.916317] RSP: 002b:00007fff5b8baee0 EFLAGS: 00000202 ORIG_RAX: 000000000000004e
[52088.916321] RAX: ffffffffffffffda RBX: 00005653466ab5f0 RCX: 00007f17a273e1d8
[52088.916324] RDX: 0000000000008000 RSI: 00005653466ab5f0 RDI: 0000000000000003
[52088.916326] RBP: 00005653466ab5f0 R08: 0000000000000003 R09: 0000000000000007
[52088.916328] R10: 0000565346586010 R11: 0000000000000202 R12: ffffffffffffff80
[52088.916330] R13: 0000000000000000 R14: 000000000000000a R15: 0000565344606430

and

journalctl -f 

shows nothing when the freeze occurs


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#4 2018-06-21 02:50:10

Askannz
Member
Registered: 2016-10-22
Posts: 36

Re: Computer freezes up in konsole

Something wonky is happening in kernel space.
Maybe run fsck on the HDD, to make sure it is not a hardware problem.
You could try upgrading your kernel, also.

EDIT : It seems like this kernel warning happens when a process has been waiting too long for IO. In your case, it could be that another process is hogging the HDD.
Run iotop and look for anything suspicious.

Last edited by Askannz (2018-06-21 02:54:31)

Offline

#5 2018-06-21 03:48:21

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

iotop shows nothing of interest....
running fsck on /dev/sda yields the following

$ sudo fsck /dev/sda
fsck from util-linux 2.32
e2fsck 1.44.2 (14-May-2018)
/dev/sda is in use.
e2fsck: Cannot continue, aborting.

and

$ ps aux | grep /dev/sda

root     29949  0.0  0.0  19528  1212 ?        D    05:42   0:00 dumpe2fs -h /dev/sda
justin   30019  0.0  0.0  10900  2232 pts/6    S+   05:47   0:00 grep /dev/sda

Not sure what is running dumpe2fs but I can't seem to stop it


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#6 2018-06-21 06:06:23

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

The drive isn't responding. How is it attached USB?
Could be an USB autosuspend issue: https://wiki.archlinux.org/index.php/Po … utosuspend
This might also be controlled by some power management daemon.

Offline

#7 2018-06-21 06:15:33

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

it's an internal HDD (so I'm assuming a sata cable? not entirely sure if laptops are built similarly to a desktop sorry hmm) and I haven't done/changed anything in my power management setttings... also I'm not sure if it's relavent but now when pressing Ctrl+Alt+T to open a console journalctl -f displays the following message

Jun 21 08:12:50 zenbook-justin kdeinit5[26552]: qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
Jun 21 08:12:50 zenbook-justin kdeinit5[26552]: This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
                                                
                                                Available platform plugins are: wayland-org.kde.kwin.qpa, eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
Jun 21 08:12:50 zenbook-justin systemd[1]: Started Process Core Dump (PID 26553/UID 0).
Jun 21 08:12:50 zenbook-justin systemd-coredump[26554]: Process 26552 (konsole) of user 1000 dumped core.
                                                        
                                                        Stack trace of thread 26552:
                                                        #0  0x00007f73985c086b raise (libc.so.6)
                                                        #1  0x00007f73985ab40e abort (libc.so.6)
                                                        #2  0x00007f73989c633c n/a (/usr/lib/libQt5Core.so.5.11.0 (deleted))
                                                        #3  0x000055f15973b360 n/a (n/a)

"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#8 2018-06-21 06:23:29

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

Looks like you ran an update and didn't reboot. This can cause trouble with dlopen'd libraries (aka "plugins")
There're usually no SATA cables in notebooks ;-)

See whether the disk responds to hdparm (whether it's in standby and whether you can wake it) and check it's condition and run a health test.
https://wiki.archlinux.org/index.php/Hdparm
https://wiki.archlinux.org/index.php/SMART

Also the output of

/sys/block/sda/queue/scheduler

(assuming the HDD is sda)

Offline

#9 2018-06-21 15:03:38

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

The disk responds to hdparm (I think), and the output of the health test is passed

$ hdparam -I /dev/sda
    /dev/sda:

ATA device, with non-removable media
        Model Number:       ST1000LM035-1RK172                      
        Serial Number:      WDE5P5NS
        Firmware Revision:  SDM1    
        Transport:          Serial, ATA8-AST, SATA 1.0a, SATA II Extensions, SATA Rev 2.5, SATA Rev 2.6, SATA Rev 3.0
Standards:
        Used: unknown (minor revision code 0x001f) 
        Supported: 10 9 8 7 6 5 
        Likely used: 10
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:    16514064
        LBA    user addressable sectors:   268435455
        LBA48  user addressable sectors:  1953525168
        Logical  Sector size:                   512 bytes
        Physical Sector size:                  4096 bytes
        Logical Sector-0 offset:                  0 bytes
        device size with M = 1024*1024:      953869 MBytes
        device size with M = 1000*1000:     1000204 MBytes (1000 GB)
        cache/buffer size  = unknown
        Form Factor: 2.5 inch
        Nominal Media Rotation Rate: 5400
Capabilities:
        LBA, IORDY(can be disabled)
        Queue depth: 32
        Standby timer values: spec'd by Standard, no device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 16
        Advanced power management level: 128
        Recommended acoustic management value: 208, current value: 208
        DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6 
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4 
             Cycle time: no flow control=120ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    SMART feature set
                Security Mode feature set
           *    Power Management feature set
           *    Write cache
           *    Look-ahead
           *    Host Protected Area feature set
           *    WRITE_BUFFER command
           *    READ_BUFFER command
           *    NOP cmd
           *    DOWNLOAD_MICROCODE
           *    Advanced Power Management feature set
                Power-Up In Standby feature set
           *    SET_FEATURES required to spinup after power up
                SET_MAX security extension
           *    48-bit Address feature set
           *    Device Configuration Overlay feature set
           *    Mandatory FLUSH_CACHE
           *    FLUSH_CACHE_EXT
           *    SMART error logging
           *    SMART self-test
           *    General Purpose Logging feature set
           *    WRITE_{DMA|MULTIPLE}_FUA_EXT
           *    64-bit World wide name
           *    IDLE_IMMEDIATE with UNLOAD
                Write-Read-Verify feature set
           *    WRITE_UNCORRECTABLE_EXT command
           *    {READ,WRITE}_DMA_EXT_GPL commands
           *    Segmented DOWNLOAD_MICROCODE
           *    Gen1 signaling speed (1.5Gb/s)
           *    Gen2 signaling speed (3.0Gb/s)
           *    Gen3 signaling speed (6.0Gb/s)
           *    Native Command Queueing (NCQ)
           *    Host-initiated interface power management
           *    Phy event counters
           *    Idle-Unload when NCQ is active
           *    READ_LOG_DMA_EXT equivalent to READ_LOG_EXT
           *    DMA Setup Auto-Activate optimization
           *    Device-initiated interface power management
                Asynchronous notification (eg. media change)
           *    Software settings preservation
           *    SMART Command Transport (SCT) feature set
           *    SCT Write Same (AC2)
           *    SCT Features Control (AC4)
           *    SCT Data Tables (AC5)
                unknown 206[12] (vendor specific)
                unknown 206[13] (vendor specific)
           *    DOWNLOAD MICROCODE DMA command
Security: 
        Master password revision code = 65534
                supported
        not     enabled
        not     locked
        not     frozen
        not     expired: security count
                supported: enhanced erase
        162min for SECURITY ERASE UNIT. 162min for ENHANCED SECURITY ERASE UNIT.
Logical Unit WWN Device Identifier: 5000c500a88b4817
        NAA             : 5
        IEEE OUI        : 000c50
        Unique ID       : 0a88b4817
Checksum: correct

$ hdparam -Tt /dev/sda
/dev/sda:
 Timing cached reads:   19426 MB in  1.99 seconds = 9739.02 MB/sec
 Timing buffered disk reads: 384 MB in  3.01 seconds = 127.51 MB/sec

$smartctl -t long /dev/sda
$smartctl -H /dev/sda
smartctl 6.6 2017-11-05 r4594 [x86_64-linux-4.14.50-1-lts] (local build)
Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

as far as the last comment....

$ sudo cat /sys/block/sda/queue/scheduler 
noop [deadline] cfq 

"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#10 2018-06-21 15:11:22

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,420

Re: Computer freezes up in konsole

Health test result: PASSED can mean the device is perfectly fine, or the device is technically dead but has not yet officially acknowledged that it is. Look at/post smartctl -a for a more relevant judgement, also make sure that you wait out the allotted time the long test mentions before calling -a as that may cause the test to be interrupted.

Offline

#11 2018-06-21 15:39:23

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

If the drive isn't toast, please try the cfq scheduler.

Offline

#12 2018-06-21 15:52:29

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

$smartctl -t short /dev/sda
$smartctl -a /dev/sda

smartctl 6.6 2017-11-05 r4594 [x86_64-linux-4.14.50-1-lts] (local build)
Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Device Model:     ST1000LM035-1RK172
Serial Number:    WDE5P5NS
LU WWN Device Id: 5 000c50 0a88b4817
Firmware Version: SDM1
User Capacity:    1,000,204,886,016 bytes [1.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    5400 rpm
Form Factor:      2.5 inches
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   ACS-3 T13/2161-D revision 3b
SATA Version is:  SATA 3.1, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Thu Jun 21 17:50:13 2018 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
Self-test execution status:      (   0) The previous self-test routine completed
                                        without error or no self-test has ever 
                                        been run.
Total time to complete Offline 
data collection:                (    0) seconds.
Offline data collection
capabilities:                    (0x71) SMART execute Offline immediate.
                                        No Auto Offline data collection support.
                                        Suspend Offline collection upon new
                                        command.
                                        No Offline surface scan supported.
                                        Self-test supported.
                                        Conveyance Self-test supported.
                                        Selective Self-test supported.
SMART capabilities:            (0x0003) Saves SMART data before entering
                                        power-saving mode.
                                        Supports SMART auto save timer.
Error logging capability:        (0x01) Error logging supported.
                                        General Purpose Logging supported.
Short self-test routine 
recommended polling time:        (   1) minutes.
Extended self-test routine
recommended polling time:        ( 162) minutes.
Conveyance self-test routine
recommended polling time:        (   2) minutes.
SCT capabilities:              (0x3035) SCT Status supported.
                                        SCT Feature Control supported.
                                        SCT Data Table supported.

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   069   064   006    Pre-fail  Always       -       8000855
  3 Spin_Up_Time            0x0003   099   099   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   099   099   020    Old_age   Always       -       1531
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   067   060   045    Pre-fail  Always       -       4629337
  9 Power_On_Hours          0x0032   099   099   000    Old_age   Always       -       995 (198 5 0)
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       922
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   099   000    Old_age   Always       -       7
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   070   054   040    Old_age   Always       -       30 (Min/Max 29/32)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       3
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       15
193 Load_Cycle_Count        0x0032   092   092   000    Old_age   Always       -       16597
194 Temperature_Celsius     0x0022   030   046   000    Old_age   Always       -       30 (0 7 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       183 (145 208 0)
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       648399170
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       824911259
254 Free_Fall_Sensor        0x0032   100   100   000    Old_age   Always       -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Short offline       Completed without error       00%       995         -
# 2  Extended offline    Completed without error       00%       992         -

SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.

and I am unsure of what you mean by try the cfq scheduler...


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#13 2018-06-21 19:26:40

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

You're current using the deadline scheduler, it's for some weird reason the default in the LTS kernel.
https://wiki.archlinux.org/index.php/Im … _scheduler

Offline

#14 2018-06-22 04:15:43

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

So I could be way off in trying to change the scheduler here.... but when I try to update the scheduler in vim to cfq I get the following error

<devices/pci0000:00/0000:00:17.0/ata1/host0/target0:0:0/0:0:0:0/block/sda/queue/scheduler"  
"/sys/devices/pci0000:00/0000:00:17.0/ata1/host0/target0:0:0/0:0:0:0/block/sda/queue/scheduler" E514: write error (file 
system full?)
WARNING: Original file may be lost or damaged
don't quit the editor until the file is successfully written!

but the output of df -h

$ df -h
Filesystem      Size  Used Avail Use% Mounted on
dev             3.9G     0  3.9G   0% /dev
run             3.9G  1.2M  3.9G   1% /run
/dev/sdb1        30G   14G   15G  50% /
tmpfs           3.9G   51M  3.8G   2% /dev/shm
tmpfs           3.9G     0  3.9G   0% /sys/fs/cgroup
tmpfs           3.9G  4.1M  3.9G   1% /tmp
/dev/sdb3        78G  5.4G   69G   8% /home
/dev/sda        916G  9.5G  860G   2% /run/media/justin/DATA
tmpfs           787M   12K  787M   1% /run/user/1000

"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#15 2018-06-22 06:41:20

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

Where does the article say "vim"?

That "file" is actually a kernel variable, if you want to invoke sudo to write into it, the general "trick" is to invoke tee (a T-pipe)

echo cfq | sudo tee /sys/block/sda/queue/scheduler

Offline

#16 2018-06-22 13:35:51

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

yikes that was my bad!! I guess I just assumed it was a regular old file rather than a kernel variable. It's now updated though so we'll see I guess!


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#17 2018-06-22 13:42:21

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

n.b. that this edit will NOT survive a reboot, you will have to repeat this or use a udev rule.

Offline

#18 2018-06-26 05:54:43

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

The problem persists even after switching the scheduler to cfq


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

#19 2018-06-27 06:36:42

seth
Member
Registered: 2012-09-03
Posts: 49,967

Re: Computer freezes up in konsole

Ok, so it's not the scheduler, the disk looks healthy and on a  notebook it's most likely not the connection either.
Does it also happen with the main kernel, https://www.archlinux.org/packages/core/x86_64/linux/ ?

Offline

#20 2018-06-30 12:31:53

jbenge1
Member
From: Az
Registered: 2018-04-09
Posts: 151

Re: Computer freezes up in konsole

current kernel version

4.17.2-1-ARCH

and I am still having the same issue hmm


"Dr. Madden, why don't the natural numbers include 0?" -me
"....... Take a philosophy course" -Dr. Madden

Offline

Board footer

Powered by FluxBB