You are not logged in.

#26 2025-03-25 21:58:41

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       8
187 Reported_Uncorrect      0x0032   097   097   000    Old_age   Always       -       3
196 Reallocated_Event_Count 0x0033   100   100   036    Pre-fail  Always       -       8

You lost some sectors - which isn't a good sign.
Make sure the numbers don't move!

/dev/fd/63 is the pipe, try from a chroot.
However, you're using the keyring from the (probably older) install iso, so what you actually want to do here is

pacman -Sy archlinux-keyring

to update the keyring of the iso.
Then check "pacman-key -l polyzen"

Offline

#27 2025-03-25 22:34:28

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

seth wrote:
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       8
187 Reported_Uncorrect      0x0032   097   097   000    Old_age   Always       -       3
196 Reallocated_Event_Count 0x0033   100   100   036    Pre-fail  Always       -       8

You lost some sectors - which isn't a good sign.
Make sure the numbers don't move!

/dev/fd/63 is the pipe, try from a chroot.
However, you're using the keyring from the (probably older) install iso, so what you actually want to do here is

pacman -Sy archlinux-keyring

to update the keyring of the iso.
Then check "pacman-key -l polyzen"

I managed to pass the key-problem and reinstalled the packages, but still can't boot. Its weird that badblocks didnt show anything, because I guess I need to get rid of the bad sectors, right?

Offline

#28 2025-03-25 22:47:21

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

There're none pending, the sectors have been reallocated.
Have you completed fsck and if so, where does the boot fail/stuck now?

On a formal note, please avoifd bloating the thread with full-quotes.

Offline

#29 2025-03-29 17:51:45

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

I tried booting, but got stuck in some issues with my monitor, which are now fixed.

It looks like this when booting:
exifread-com-clean-IMG-3147.jpg

and this after doing fsck, so I cant boot and cant fix it either:

https://0x0.st/8eDo.txt

Last edited by dratos97391 (2025-03-29 17:54:16)

Offline

#30 2025-03-29 18:19:37

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

If multiple iterations of fsck cannot fix that inode, try to brute-force fix it and delete /mnt/var/log/journal from the iso.
This might not work as well and you'll have to resort to debugfs, https://unix.stackexchange.com/question … delete-and
removing the bogus ".." should™ suffice for a subsequent fsck BUT MAKE SURE TO HAVE BACKUPS!

Offline

#31 2025-03-29 19:57:35

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

I needed t o use debugfs to remove the folder:

# rm -rf journal
rm: cannot remove 'journal/988d74bf42aa4e75b41a4f601f305e1b': Directory not empty

# umount /mnt
root@archiso / # debugfs -w  /dev/sda1
debugfs 1.47.1 (20-May-2024)
debugfs:  unlink /var/log/journal
debugfs:  unlink /var/log/journal/988d74bf42aa4e75b41a4f601f305e1b/.
/var/log/journal/988d74bf42aa4e75b41a4f601f305e1b: File not found by ext2_lookup 
debugfs:  unlink /var/log/journal/988d74bf42aa4e75b41a4f601f305e1b/..
/var/log/journal/988d74bf42aa4e75b41a4f601f305e1b: File not found by ext2_lookup 
debugfs:  unlink /var/log/journal/988d74bf42aa4e75b41a4f601f305e1b
/var/log/journal: File not found by ext2_lookup 
debugfs:  quit

# mount /dev/sda1 /mnt
root@archiso / # ls /mnt/var/log

But fsck is not happy, still:

# fsck /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Unconnected directory inode 6554008 (was in /var/log)
Connect to /lost+found<y>? yes
'..' in /lost+found/#6554008/988d74bf42aa4e75b41a4f601f305e1b (6554612) is <The NULL inode> (0), should be /lost+found/#6554008 (6554008).
Fix<y>? yes
Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Inode 6554008 ref count is 3, should be 2.  Fix<y>? yes
Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949443/9502720 files (0.2% non-contiguous), 25955735/38010624 blocks
fsck /dev/sda1  6.58s user 2.49s system 13% cpu 1:09.31 total

Last edited by dratos97391 (2025-03-29 20:04:27)

Offline

#32 2025-03-30 06:33:44

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

You found another instance of the same problem, same approach there (lost+found is actually populated by fsck)
The FS is seriously corrupted, you do have backups of everything important on that drive (ie. stuff you cannot download from the internet)?

Prepare for some data loss and keep a very close eye on the smart data of that drive.
Any movement in reallocated or pending blocks etc. is a strong indication that it's EOL.

Offline

#33 2025-03-30 15:47:54

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

Thanks,

Everything is backed up on another disk, and the rsync I ran in the beginning of this session of trouble shooting went fine.

I removed it, but it keeps being found by fsck,
I dont really want to remove /lost+found, seems like it could break things.

# debugfs -w  /dev/sda1
debugfs 1.47.1 (20-May-2024)
debugfs:  unlink '/lost+found/#6554008/988d74bf42aa4e75b41a4f601f305e1b'
'/lost+found/#6554008: File not found by ext2_lookup 
debugfs:  unlink /lost+found/#6554008/988d74bf42aa4e75b41a4f601f305e1b
debugfs:  quit
root@archiso ~ # fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Unconnected directory inode 6554612 (was in /lost+found)
Connect to /lost+found? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Inode 6554612 ref count is 2, should be 1.  Fix? yes

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949443/9502720 files (0.2% non-contiguous), 25955735/38010624 blocks
fsck -y /dev/sda1  7.10s user 2.40s system 23% cpu 40.366 total
# fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
'..' in /lost+found/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found (11).
Fix? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Pass 5: Checking group summary information

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949443/9502720 files (0.2% non-contiguous), 25955735/38010624 blocks
fsck -y /dev/sda1  6.83s user 2.33s system 22% cpu 40.180 total
# debugfs -w  /dev/sda1
debugfs 1.47.1 (20-May-2024)
debugfs:  unlink /lost+found/#6554612
debugfs:  quit
root@archiso ~ # fsck -y /dev/sda1 
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Unconnected directory inode 6554612 (was in /lost+found)
Connect to /lost+found? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Inode 6554612 ref count is 2, should be 1.  Fix? yes

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949443/9502720 files (0.2% non-contiguous), 25955735/38010624 blocks
fsck -y /dev/sda1  6.67s user 2.25s system 22% cpu 39.483 total

Offline

#34 2025-03-30 20:13:25

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

lost+found will be recreated by fsck - have you checked that the evil numbers in smartctl aren't creeping up at you?

Offline

#35 2025-03-31 20:16:41

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

A third smartctl test is started, will write back the results if the variables change:

# smartctl -l selftest /dev/sda1
smartctl 7.4 2023-08-01 r5530 [x86_64-linux-6.10.7-arch1-1] (local build)
Copyright (C) 2002-23, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF READ SMART DATA SECTION ===
SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Extended offline    Self-test routine in progress 90%     12545         -
# 2  Extended offline    Completed without error       00%     12464         -
# 3  Extended offline    Completed without error       00%     57812         -

root@archiso ~ # smartctl -t long /dev/sda1    
smartctl 7.4 2023-08-01 r5530 [x86_64-linux-6.10.7-arch1-1] (local build)
Copyright (C) 2002-23, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
Can't start self-test without aborting current test (90% remaining),
add '-t force' option to override, or run 'smartctl -X' to abort test.

results:

 # sudo smartctl -a /dev/sda
smartctl 7.4 2023-08-01 r5530 [x86_64-linux-6.10.7-arch1-1] (local build)
Copyright (C) 2002-23, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate Momentus 7200.4
Device Model:     ST9160412AS
Serial Number:    5VH66A0Y
LU WWN Device Id: 5 000c50 037f57132
Firmware Version: 0006HPM1
User Capacity:    160,041,885,696 bytes [160 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    7200 rpm
Form Factor:      2.5 inches
Device is:        In smartctl database 7.3/5528
ATA Version is:   ATA8-ACS T13/1699-D revision 4
SATA Version is:  SATA 2.6, 3.0 Gb/s
Local Time is:    Tue Apr  1 05:33:38 2025 UTC
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:      (  25)	The self-test routine was aborted by
					the host.
Total time to complete Offline 
data collection: 		(    0) seconds.
Offline data collection
capabilities: 			 (0x53) SMART execute Offline immediate.
					Auto Offline data collection on/off support.
					Suspend Offline collection upon new
					command.
					No Offline surface scan supported.
					Self-test supported.
					No 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: 	 (   2) minutes.
Extended self-test routine
recommended polling time: 	 (  42) minutes.
SCT capabilities: 	       (0x103f)	SCT Status supported.
					SCT Error Recovery Control 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   111   099   006    Pre-fail  Always       -       41072574
  3 Spin_Up_Time            0x0002   098   097   000    Old_age   Always       -       0
  4 Start_Stop_Count        0x0033   100   100   000    Pre-fail  Always       -       822
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       8
  7 Seek_Error_Rate         0x000f   075   060   030    Pre-fail  Always       -       34639729819
  9 Power_On_Hours          0x0032   011   011   000    Old_age   Always       -       78090
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0033   100   037   020    Pre-fail  Always       -       815
183 Runtime_Bad_Block       0x0032   100   253   000    Old_age   Always       -       0
184 End-to-End_Error        0x0033   100   100   097    Pre-fail  Always       -       0
187 Reported_Uncorrect      0x0032   097   097   000    Old_age   Always       -       3
188 Command_Timeout         0x0032   100   099   000    Old_age   Always       -       17180131336
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   067   046   045    Old_age   Always       -       33 (Min/Max 21/39)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       37
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       9
193 Load_Cycle_Count        0x0032   001   001   000    Old_age   Always       -       6194976
194 Temperature_Celsius     0x0022   033   054   000    Old_age   Always       -       33 (0 5 0 0 0)
195 Hardware_ECC_Recovered  0x001a   054   054   000    Old_age   Always       -       41072574
196 Reallocated_Event_Count 0x0033   100   100   036    Pre-fail  Always       -       8
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
254 Free_Fall_Sensor        0x0032   100   100   000    Old_age   Always       -       0

SMART Error Log Version: 1
ATA Error Count: 3
	CR = Command Register [HEX]
	FR = Features Register [HEX]
	SC = Sector Count Register [HEX]
	SN = Sector Number Register [HEX]
	CL = Cylinder Low Register [HEX]
	CH = Cylinder High Register [HEX]
	DH = Device/Head Register [HEX]
	DC = Device Command Register [HEX]
	ER = Error register [HEX]
	ST = Status register [HEX]
Powered_Up_Time is measured from power on, and printed as
DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
SS=sec, and sss=millisec. It "wraps" after 49.710 days.

Error 3 occurred at disk power-on lifetime: 50222 hours (2092 days + 14 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: WP at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  61 00 08 ff ff ff 4f 00  23d+21:25:29.542  WRITE FPDMA QUEUED
  61 00 08 98 9a 72 46 00  23d+21:25:29.541  WRITE FPDMA QUEUED
  60 00 08 ff ff ff 4f 00  23d+21:25:29.541  READ FPDMA QUEUED
  60 00 08 28 0a 63 46 00  23d+21:25:29.540  READ FPDMA QUEUED
  60 00 20 98 09 63 46 00  23d+21:25:29.540  READ FPDMA QUEUED

Error 2 occurred at disk power-on lifetime: 50222 hours (2092 days + 14 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  60 00 08 28 0a 63 46 00  23d+21:25:26.811  READ FPDMA QUEUED
  60 00 20 98 09 63 46 00  23d+21:25:26.811  READ FPDMA QUEUED
  60 00 08 58 09 63 46 00  23d+21:25:26.811  READ FPDMA QUEUED
  60 00 08 ff ff ff 4f 00  23d+21:25:26.809  READ FPDMA QUEUED
  61 00 08 20 af 06 49 00  23d+21:25:26.809  WRITE FPDMA QUEUED

Error 1 occurred at disk power-on lifetime: 50222 hours (2092 days + 14 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  60 00 18 ff ff ff 4f 00  23d+21:25:23.893  READ FPDMA QUEUED
  60 00 08 08 b0 3e 4a 00  23d+21:25:23.887  READ FPDMA QUEUED
  60 00 08 00 b0 3e 4a 00  23d+21:25:23.871  READ FPDMA QUEUED
  60 00 08 38 08 40 46 00  23d+21:25:23.809  READ FPDMA QUEUED
  60 00 08 00 13 00 48 00  23d+21:25:23.791  READ FPDMA QUEUED

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Extended offline    Aborted by host               90%     12546         -
# 2  Extended offline    Completed without error       00%     12546         -
# 3  Extended offline    Completed without error       00%     12464         -
# 4  Extended offline    Completed without error       00%     57812         -

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.

Last edited by dratos97391 (2025-04-01 05:34:32)

Offline

#36 2025-04-01 05:49:02

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

No movement so far - you btw. don't have to run self-checks, bad IO leading to sector re-allocation will be logged automatically.

Offline

#37 2025-04-01 07:33:35

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

Yes it seems like that.

I feel like the file /var/log/journal/988d74bf42aa4e75b41a4f601f305e1b/. with INODE errors just moved to /lost+found/#6554008/988d74bf42aa4e75b41a4f601f305e1b when I unlinked it and the system can't boot until its resolved.

I dont know how to tell fsck to just ignore this file and proceed, my google-fu havent provided me with a working solution. Are there any way to just to purge the file and all related items?

Offline

#38 2025-04-01 13:07:50

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

Did you try to remove the lost+found directory?

Offline

#39 2025-04-01 15:36:07

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

I. tried unlinking the folder twice, and ran fsck three times. With the same result, fsck cannot succeed.

# debugfs -w  /dev/sda1
debugfs 1.47.1 (20-May-2024)
debugfs:  unlink /lost+found
debugfs:  quit
root@archiso ~ # fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Unconnected directory inode 11 (was in /)
Connect to /lost+found? yes

/lost+found not found.  Create? yes

'..' in /lost+found/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#11 (11).
Fix? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 3A: Optimizing directories
Pass 4: Checking reference counts
Inode 11 ref count is 1234, should be 1233.  Fix? yes

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949444/9502720 files (0.2% non-contiguous), 25955744/38010624 blocks
fsck -y /dev/sda1  6.26s user 2.29s system 19% cpu 42.763 total
4 root@archiso ~ # debugfs -w  /dev/sda1
debugfs 1.47.1 (20-May-2024)
debugfs:  unlink /lost+found
debugfs:  quit
root@archiso ~ # fsck -y /dev/sda1    
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Unconnected directory inode 17 (was in /)
Connect to /lost+found? yes

/lost+found not found.  Create? yes

'..' in /lost+found/#17/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#17/#11 (11).
Fix? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Inode 17 ref count is 4, should be 3.  Fix? yes

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949445/9502720 files (0.2% non-contiguous), 25955745/38010624 blocks
fsck -y /dev/sda1  6.33s user 2.28s system 20% cpu 42.767 total
4 root@archiso ~ # fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
'..' in /lost+found/#17/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#17/#11 (11).
Fix? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Pass 5: Checking group summary information

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 949445/9502720 files (0.2% non-contiguous), 25955745/38010624 blocks
fsck -y /dev/sda1  6.39s user 2.22s system 21% cpu 39.311 total

Offline

#40 2025-04-01 20:35:38

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

Edit: check this one first
Does "/lost+found/#17/#11" currently exist?
https://csic.som.emory.edu/~lzhou/blogs/?p=70 - but this requires you to mount the filesystem and delete files…

and only then maybe "e2fsck -cckv", https://man.archlinux.org/man/core/e2fs … sck.8.en#c

Last edited by seth (2025-04-01 20:36:17)

Offline

#41 2025-04-02 17:38:49

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

I logged in an the file does exist.

/mnt # cd lost+found 
root@archiso /mnt/lost+found # ls
'#17'
root@archiso /mnt/lost+found # ls 
'#17'
root@archiso /mnt/lost+found # ls '#17'
'#11'
root@archiso /mnt/lost+found # ls '#17/#11'
'#401458'   '#6179186'  '#6557687'  '#6561941'  '#6566563'  '#6570756'  '#6574728'  '#6578800'  '#6582549'  '#6586621'  '#6599656'  '#6951642'  '#7087744'  '#7108281'
... many lines like this...
'#6179185'  '#6557680'  '#6561937'  '#6566553'  '#6570736'  '#6574701'  '#6578783'  '#6582547'  '#6586616'  '#6599655'  '#6951632'  '#7087738'  '#7108244'
# cd '#17'
root@archiso /mnt/lost+found/#17 # touch test
root@archiso /mnt/lost+found/#17 # rm test
root@archiso /mnt/lost+found/#17 # cd ..
root@archiso /mnt/lost+found # ls -al
total 12
drwx------  3 root root 4096 Apr  1 15:32  .
drwxr-xr-x 19 root root 4096 Mar 24 21:32  ..
drwxr-xr-x  3 root root 4096 Apr  2 16:23 '#17'

# umount /mnt
root@archiso / # fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1 contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
'..' in /lost+found/#17/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#17/#11 (11).
Fix? yes

Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts
Pass 5: Checking group summary information

/dev/sda1: ********** WARNING: Filesystem still has errors **********

/dev/sda1: 941283/9502720 files (0.2% non-contiguous), 24812215/38010624 blocks
fsck -y /dev/sda1  6.25s user 2.34s system 22% cpu 38.560 total

Im running # fsck -cckv /dev/sda1 with unmounted /mnt now
which gave this output:

 # fsck -cckv /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
Checking for bad blocks (non-destructive read-write test)
Testing with random pattern: done                                                 
/dev/sda1: Updating bad block inode.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
'..' in /lost+found/#17/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#17/#11 (11).
Fix<y>? yes
Couldn't fix parent of inode 6554612: Couldn't find parent directory entry

Pass 4: Checking reference counts

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

/dev/sda1: ********** WARNING: Filesystem still has errors **********


      941283 inodes used (9.91%, out of 9502720)
        1381 non-contiguous files (0.1%)
         406 non-contiguous directories (0.0%)
             # of inodes with ind/dind/tind blocks: 0/0/0
             Extent depth histogram: 904427/379
    24812215 blocks used (65.28%, out of 38010624)
           0 bad blocks
           3 large files

      762404 regular files
      138756 directories
          42 character device files
           1 block device file
           0 fifos
        5978 links
       40024 symbolic links (36377 fast symbolic links)
          47 sockets
------------
      947252 files
fsck -cckv /dev/sda1  143.61s user 369.19s system 1% cpu 9:32:20.10 total

will run the command a second time to compare

Last edited by dratos97391 (2025-04-03 05:21:00)

Offline

#42 2025-04-02 20:01:07

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

Did you try to "rm -rf /mnt/lost+found/*" and then run fsck, resp. inspect the file ownerships are mentioned in the (slightly *cough* dated) blog I linked?

Offline

#43 2025-04-03 05:23:15

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

No, I didnt remove lost+found, because the guide didnt write so explicity and I also noticed that there are a shitload of files there. I have the output of  fsck -cckv /dev/sda1 in the post above though.

Offline

#44 2025-04-03 06:48:40

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

Not the lost+found directory itself and

seth also, well - almost, including a typo wrote:

inspect the file ownerships a(s) mentioned

The Blog wrote:

[SOLUTION]

When fsck is done, mount the FS.  Then cd the lost+found/ directory:

mount #<your mount point>
cd #<your mount point>
cd lost+found

If you do ‘ls -al’, you will see a directory with zero length named #<the affected inode>, like here #122068977.

It usually has a weird owner and group number.

You then do the following:

chown root:root #<the affected inode>
chmod 755 #<the affected inode>

This will make it look normal.

Then

cd #<the affected inode>
touch test
rm test
cd #<your mount point>

Note you cannot do

cd ..

still here since ‘..’ does not exist yet.

Then if you do
ls -al [in the lost+found dir

again, the length of the directory #<the affected inode> is no longer 0, but the default minimum length of your file system, say 4096, 8192, or 16384, etc.

At this point, you can cd off the mounted filesystem, and umount it:

cd ~
umount #<your mount point>

and fsck it:
fsck -y /dev/<your device>

It then will result:

fsck 1.40.2 (12-Jul-2007)
e2fsck 1.40.2 (12-Jul-2007)
<your FS> was not cleanly unmounted, check forced.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Missing '.' in directory inode <bad inode number>.
Fix? yes

Setting filetype for entry '.' in ... (<bad inode number>) to 2.
Missing '..' in directory inode <bad inode number>.
Fix? yes

Setting filetype for entry '..' in ... (<bad inode number>) to 2.
Pass 3: Checking directory connectivity
'..' in /lost+found/<bad inode number> (<bad inode number>) is
(0), should be /lost+found (11).
Fix? yes

Pass 4: Checking reference counts
Inode 2 ref count is 6, should be 7. Fix? yes

Inode 11 ref count is 4, should be 3. Fix? yes

Inode <bad inode number> ref count is 1, should be 2. Fix? yes

Pass 5: Checking group summary information

<your FS>: ***** FILE SYSTEM WAS MODIFIED *****
<your FS>: 1882918/91193344 files (0.3% non-contiguous), 111803861/182339584 blocks

This will save you from the risk of running a FS with errors or fully copy the file system elsewhere to recreate it.

Offline

#45 2025-04-03 13:48:13

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

This is the files in lost+found, contains a lot of packages, probably the ones I had a problem with earlier:

https://0x0.st/82gg.txt

I am focusing on the inode /lost+found/#17/#11/#6554612

# cd 'lost+found/#17/#11/#6554612' 
root@archiso /mnt/lost+found/#17/#11/#6554612 # chown root:root 'lost+found/#17/#11/#6554612'
chown: cannot access 'lost+found/#17/#11/#6554612': No such file or directory
1 root@archiso /mnt/lost+found/#17/#11/#6554612 # chown root:root '/mnt/lost+found/#17/#11/#6554612'
root@archiso /mnt/lost+found/#17/#11/#6554612 # chmod 755 '/mnt/lost+found/#17/#11/#6554612'
root@archiso /mnt/lost+found/#17/#11/#6554612 # touch test
root@archiso /mnt/lost+found/#17/#11/#6554612 # rm test
root@archiso /mnt/lost+found/#17/#11/#6554612 # cd /mnt
root@archiso /mnt # cd ..
root@archiso / # 

This shows that .. seems to work, I proceeded to remove the contents of lost+found:

root@archiso /mnt # rm -rf lost+found/*
zsh: sure you want to delete the only file in /mnt/lost+found [yn]? y

rm: cannot remove 'lost+found/#17/#11/#6554612': Directory not empty

root@archiso /mnt/lost+found # cd lost+found
130 root@archiso /mnt/lost+found # cd '#17/#11/#6554612'
root@archiso /mnt/lost+found/#17/#11/#6554612 # ls
root@archiso /mnt/lost+found/#17/#11/#6554612 # rmc
130 root@archiso /mnt/lost+found/#17/#11/#6554612 # cd ..
root@archiso /mnt/lost+found/#17/#11 # rmdir '#6554612'
rmdir: failed to remove '#6554612': Directory not empty
1 root@archiso /mnt/lost+found/#17/#11 # ls -la '#6554612'
total 0
root@archiso /mnt/lost+found/#17/#11 # rm -rf '#6554612'
rm: cannot remove '#6554612': Directory not empty
1 root@archiso /mnt/lost+found/#17/#11
# touch test
root@archiso /mnt/lost+found/#17/#11/#6554612 # rm test
root@archiso /mnt/lost+found/#17/#11/#6554612 # cd ..
root@archiso /mnt/lost+found/#17/#11 # 

We are stuck at the unlink problem again smile but im  going to unmount /mnt and try fsck, and then I got;

# fsck -cckyv /dev/sda1
fsck from util-linux 2.40.2                                                                                                                                                    
e2fsck 1.47.1 (20-May-2024)                                                                                                                                                    
Checking for bad blocks (non-destructive read-write test)                                                                                                                      
Testing with random pattern:  31.13% done, 1:35:45 elapsed. (0/0/0 errors)                                                                                                     
 31.14% done, 1:35:46 elapsed. (0/0/0 errors)                                                                                                                                  
 78.04% done, 4:09:09 elapsed. (0/0/0 errors)                                                                                                                                  
                                                                                                                                                                               
done            
/dev/sda1: Updating bad block inode.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Missing '.' in directory inode 6554612.
Fix? yes

Missing '..' in directory inode 6554612.
Fix? yes

Pass 3: Checking directory connectivity
'..' in /lost+found/#17/#11/#6554612 (6554612) is <The NULL inode> (0), should be /lost+found/#17/#11 (11).
Fix? yes

Pass 4: Checking reference counts
Inode 2 ref count is 18, should be 19.  Fix? yes

Inode 6554612 ref count is 1, should be 2.  Fix? yes

Pass 5: Checking group summary information

/dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****

      924186 inodes used (9.73%, out of 9502720)
        1108 non-contiguous files (0.1%)
         402 non-contiguous directories (0.0%)
             # of inodes with ind/dind/tind blocks: 0/0/0
             Extent depth histogram: 887582/235
    22938283 blocks used (60.35%, out of 38010624)
           0 bad blocks
           3 large files

      746944 regular files
      137420 directories
          41 character device files
           1 block device file
           0 fifos
        5158 links
       39725 symbolic links (36271 fast symbolic links)
          46 sockets
------------
      929335 files

and finally:

# fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1: clean, 924186/9502720 files, 22938283/38010624 blocks

Last edited by dratos97391 (2025-04-03 13:48:47)

Offline

#46 2025-04-03 21:04:44

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

# fsck -y /dev/sda1
fsck from util-linux 2.40.2
e2fsck 1.47.1 (20-May-2024)
/dev/sda1: clean, 924186/9502720 files, 22938283/38010624 blocks

Errr… so the problem is now gone?

Offline

#47 2025-04-04 06:50:59

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

Yes one problem is gone, I can boot to the OS but cant login.

I have been trying to debug it. But I cannot login to the machine, so Im suspecting some type of harddisk problems?

ping and ssh doesnt work:

ping: sendto: Host is down
ssh: connect to host 192.168.1.232 port 37261: Host is down

Logging in via the terminal directly just fails, when I type the username "dratos" I get
"Login incorrect" shown for a second and get back to the prompt, same for user root.

I tried setting passwd when chrooted with a live-usb, and I see that my user exists in /etc/passwd, but it doesnt change anything.

Last edited by dratos97391 (2025-04-04 06:51:34)

Offline

#48 2025-04-04 07:21:09

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

From the iso, w/o chrooting:

sudo LC_ALL=C pacman --root=/mnt -Qkk | grep -v ', 0 altered files' | grep -v backup

Offline

#49 Yesterday 19:09:07

dratos97391
Member
Registered: 2016-08-04
Posts: 44

Re: pacman says: failed to commit transaction (conflicting files)

Hi, I ran the command and got

http://0x0.st/8_KB.txt


A lot of warnings to stderr that 2&> didnt manage to catch was also shown, and the packages are the same ones I reinstalled:

warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/find-made.d.ts (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/find-made.d.ts.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/find-made.js (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/find-made.js.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/index.d.ts (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/index.d.ts.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/index.js (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/index.js.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-manual.d.ts (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-manual.d.ts.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-manual.js (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-manual.js.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-native.d.ts (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-native.d.ts.map (Modification time mismatch)
warning: npm: /mnt/usr/lib/node_modules/npm/node_modules/cacache/node_modules/mkdirp/dist/cjs/src/mkdirp-native.js (Modification time mismatch)
..... and so on for 

Offline

#50 Today 07:29:52

seth
Member
Registered: 2012-09-03
Posts: 62,401

Re: pacman says: failed to commit transaction (conflicting files)

lvm2: 172 total files, 5 altered files
systemd: 1568 total files, 8 altered files
util-linux: 538 total files, 4 altered files
util-linux-libs: 79 total files, 1 altered file
glibc: 1616 total files, 3 altered files

spells trouble, npm, nodejs and SDL have taken severe damage.

In doubt just re-install all packages

Offline

Board footer

Powered by FluxBB