You are not logged in.
I am trying to do an offline install of Arch but can no longer copy the filesystem to the hard drive.
mount /dev/sda3 /mnt (mounts fine)
cp -ax / /mnt (fails)
Cannot create directory /mnt no such file or directory
Versions prior would copy fine but it fails now.
Any idea what is wrong here?
Offline
What are you trying to accomplish with the cp command? In particular, what do you expect from the -x flag?
Offline
The "x" flag instructs cp to stay on this filesystem. The flags were taken directly from the documentation.
Please have a look here: https://wiki.archlinux.org/title/Offlin … opy_Method
Last edited by NaNaN (2022-05-13 15:35:48)
Offline
So, you want to copy the contents of the iso to a file system on your drive. A little context helps.
What commands preceded the mount command?
And:
blkid
lsblk
stat /mnt
Offline
Tucuxi, the command prior to 'cp' was newfs. This was supposed to be a fresh install.
newfs.ext4 /dev/sda3
mount...
File: /mnt
Size: 4096 Blocks: 8 IO Block: 4096 directory
Device: 8,3 Inode: 2 Links: 3
Access: (0755/drwxr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2022-05-13 09:38:26.000000000 +0000
Modify: 2022-05-13 09:38:26.000000000 +0000
Change: 2022-05-13 09:38:26.000000000 +0000
Birth: 2022-05-13 09:38:26.000000000 +0000
/dev/sdb2: SEC_TYPE="msdos" LABEL_FATBOOT="ARCHISO_EFI" LABEL="ARCHISO_EFI" UUID="0546-6611" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="bff8ee56-02"
/dev/sdb1: BLOCK_SIZE="2048" UUID="2022-05-01-09-16-25-00" LABEL="ARCH_202205" TYPE="iso9660" PARTUUID="bff8ee56-01"
/dev/loop0: TYPE="squashfs"
/dev/sda2: UUID="5d486167-fb14-4582-9724-55f60a034f87" TYPE="swap" PARTUUID="7c460021-2e2b-3f47-ac73-6823acace1a8"
/dev/sda3: UUID="e3bdc423-59a3-4f31-aa22-0876c6c5d907" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="f509041e-49fe-7044-9b29-3bf3cf9ce4cc"
/dev/sda1: UUID="4CA0-3491" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="0e04b5f8-564d-6945-9d04-170aa5087489"
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
loop0 7:0 0 669.2M 1 loop /run/archiso/airootfs
sda 8:0 0 298.1G 0 disk
├─sda1 8:1 0 128M 0 part
├─sda2 8:2 0 32G 0 part
└─sda3 8:3 0 266G 0 part /mnt
sdb 8:16 1 14.5G 0 disk /run/archiso/bootmnt
├─sdb1 8:17 1 748M 0 part
└─sdb2 8:18 1 78M 0 part
sr0 11:0 1 1024M 0 rom
Last edited by NaNaN (2022-05-13 16:58:09)
Offline
And what exactly are you trying to install. As far as I know, newfs is not available in Arch.
Ryzen 5900X 12 core/24 thread - RTX 3090 FE 24 Gb, Asus B550-F Gaming MB, 128Gb Corsair DDR4, Cooler Master N300 chassis, 5 HD (2 NvME PCI, 4SSD) + 1 x optical.
Linux user #545703
/ is the root of all problems.
Offline
That looks reasonable. Try the cp command with -v, perhaps it gives a clue what goes wrong.
Offline
Tucuxi, I tried with the -v flag and I get the same message: "Cannot create directory /mnt no such file or directory"
I'm at a loss here. Does anyone know what's happening with this?
Offline
Let's see if we can get any hints from findmnt.
findmnt --real
Offline
Tucuxi, here is the output of fndmnt:
TARGET SOURCE FSTYPE OPTIONS
/run/archiso/bootmnt /dev/sdb1 iso9660 ro,relatime,nojoliet,check=s,map=n,blocksize=2048,iocharset=utf8
/run/archiso/airootfs /dev/loop0 squashfs ro,relatime,errors=continue
sdb1 is the USB stick with arch on it.
Offline
The output shows that /dev/sda3 is not mounted. That explains the error message from the cp command. Try
mkdir -p /mnt
mount -v /dev/sda3 /mnt
And check the output of dmesg for any hints if mount fails.
Offline
Tucuxi, You were right, sda3 wasn't mounted at the time I ran the findmnt command. I mounted sda3 using the -v flag and no errors were thrown.
For clarity, I am not having an issue mounting the partition, I am having an issue with the copy command.
Even after sda3 is mounted, the copy operation still fails with "Cannot create directory /mnt no such file or directory."
Here is the output of findmnt with sda3 mounted:
TARGET SOURCE FSTYPE OPTIONS
/run/archiso/bootmnt /dev/sdb1 iso9660 ro,relatime,nojoliet,check=s,map=n,blocksize=2048,iocharset=utf8
/run/archiso/airootfs /dev/loop0 squashfs ro,relatime,errors=continue
/mnt /dev/sda3 ext4 rw,relatime
Then, after a successful mount, I copy:
cp -ax / /mnt
Cannot create directory /mnt no such file or directory.
Offline
It starts copying when used:
cp -v -a -x /* /mnt
Consider to use rsync instead.
Offline
Fixxer, thanks for the reply.
I am aware that using a wildcard will copy but when you drop the -v flag, you'll see there are IO errors and an Invalid argument that occur. Also, I started this copy operation literally 10 minutes ago and it's still copying.
Using cp -ax / /mnt, would copy in less than a minute. Something isn't right here.
Offline