You are not logged in.

#1 2021-06-28 20:11:42

paulbarbee
Member
Registered: 2010-08-20
Posts: 49

cannot install xkeyboard-config, error conflicting files /var [SOLVED]

I recently installed Arch on an SSD. I have a small SSD and a 1TB HDD. I am dual-booting Arch & Windows. I installed Arch just on the HDD at first, but that's slow, so I installed it to the SSD then used bind in fstab to mount the /home, /var & /tmp directories on the HDD. So far Arch boots, and pacman doesn't seem to have any problems, until I install xkeyboard-config or xorg-server. I can install update or remove other packages, but when I try to install xkeyboard-config, I get the following errors:

error: failed to commit transaction (conflicting files)
xkeyboard-config: /var exists in filesystem
Errors occurred, no packages were upgraded.

I have used pacman -o to make sure that no package own /var or /var/lib.

My fstab is below. Thank you in advance for any help!

# /dev/nvme0n1p5
UUID=cbb6c2c8-2aa3-42b9-b595-45ffc817fb3c	/         	ext4      	rw,relatime,stripe=32	0 1

# /dev/nvme0n1p2 LABEL=SYSTEM
UUID=94AD-5B95      	/boot     	vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro	0 2

# /dev/sda3
UUID=d4ea04e5-8f4f-47b5-a4f8-537348b38be2	/mnt/sda3 	ext4      	rw,relatime	0 2


# binds
/mnt/sda3/home	/home	none	defaults,bind	0	2
/mnt/sda3/tmp	/tmp	none	defaults,bind	0	2
/mnt/sda3/var	/var	none	defaults,bind	0	2

Last edited by paulbarbee (2021-06-30 05:21:23)

Offline

#2 2021-06-28 22:40:52

Scimmia
Fellow
Registered: 2012-09-01
Posts: 13,729

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

what does `stat /var` give you?

Offline

#3 2021-06-29 02:02:18

paulbarbee
Member
Registered: 2010-08-20
Posts: 49

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

Thank you for your help.

'stat /var' gave me:

  Size: 13        	Blocks: 0          IO Block: 4096   symbolic link
Device: 10305h/66309d	Inode: 17          Links: 1
Access: (0777/lrwxrwxrwx)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2021-06-27 23:29:32.856842567 -0500
Modify: 2021-06-27 23:29:19.366842912 -0500
Change: 2021-06-27 23:29:19.366842912 -0500
 Birth: 2021-06-27 23:29:19.366842912 -0500

I then tried to run 'man stat'. That gave me an error, so I thought man-db wasn't installed, so I ran pacman -S man.

That gave me the following:

resolving dependencies...
looking for conflicting packages...

Packages (1) man-db-2.9.4-2

Total Installed Size:  2.26 MiB
Net Upgrade Size:      0.00 MiB

checking keyring...
checking package integrity...
loading package files...
checking for file conflicts...
checking available disk space...
:: Processing package changes...
reinstalling man-db...
:: Running post-transaction hooks...
(1/3) Reloading system manager configuration...
(2/3) Creating temporary files...
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/cache.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib/systemd.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib/systemd.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/lib.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/cache.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/74458a6045d743a6803c7b1e0859713b.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/74458a6045d743a6803c7b1e0859713b.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/74458a6045d743a6803c7b1e0859713b.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/remote.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/74458a6045d743a6803c7b1e0859713b/system.journal.
Detected unsafe path transition /mnt/sda3 → /mnt/sda3/var during canonicalization of /var/log/journal/74458a6045d743a6803c7b1e0859713b/system.journal.
(3/3) Arming ConditionNeedsUpdate...

While I was trying to solve that error, somehow it gave me the error that /var didn't exist, so I rebooted. I was trying to re-install pacman when it started saying /var did not exist.

As the system currently stands, there is a /var which looks more or less right. I have no idea how it got there. It is not the /var on /mnt/sda3. The only command I can think of that I gave the system, that could have that effect was chown root:root /var /etc /usr /var/lib

The system is saying that pacman is not installed and the pacman-*.zst file does not exist in /var/cache/pacman, but it does exist in /mnt/sda3/var/cache/pacman

I'm going to try tomorrow to arch-chroot into the system and pacstrap pacman then re-establish the symlink between /var and /mnt/sda3/var

I do not think this is a SMART error because 1) The disk has been operational for about a month or two. and 2) Windows is using another partition on the same drive and I have not noticed any errors. This message was actually written from that partition.

Offline

#4 2021-06-29 02:22:08

Scimmia
Fellow
Registered: 2012-09-01
Posts: 13,729

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

The issue is that /var should be a dir, not a symlink. That's the point of bind mounts.

Offline

#5 2021-06-29 02:39:24

paulbarbee
Member
Registered: 2010-08-20
Posts: 49

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

Am I doing /home and /tmp wrong too then? They are symlinks at the moment.

Offline

#6 2021-06-29 06:41:02

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,331

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

You are, these are supposed to be directories and you will have similar issues on filesystem package updates.

Offline

#7 2021-06-29 06:47:51

WorMzy
Administrator
From: Scotland
Registered: 2010-06-16
Posts: 13,635
Website

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

Mod note: Not an installation issue, moving to NC.


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#8 2021-06-30 05:19:14

paulbarbee
Member
Registered: 2010-08-20
Posts: 49

Re: cannot install xkeyboard-config, error conflicting files /var [SOLVED]

Thank you@V1del! Making /home /var and /tmp empty directories solved this issue. I did have to use --overwrite to get pacman to install, since it was complaining about /usr/bin/pacman existing. After that everything went smoothly and I've  been able to install and remove any package I needed to. This message was written from within the LXQT desktop environment in Arch. I consider the issue solved.

Offline

Board footer

Powered by FluxBB