You are not logged in.

#1 2015-07-14 11:57:03

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Can't ln -s System.map file

Hi guys,

Hope you can help me smile

I'm running my own Kernel and have followed the Arch wiki here: https://wiki.archlinux.org/index.php/Ke … System.map

Im up to the part where I have to copy over my System.map file and then symlink it to System.map in the /boot directory.
But i'm running into a problem where I cannot create the Symlink.
Here is what happens -

[stephen@Xen boot]$ ls
EFI
initramfs-4.0.0-ck1-ARCH-Stephen-BFS.img
initramfs-linux-fallback.img
initramfs-linux.img
initramfs-linux-lts-fallback.img
initramfs-linux-lts.img
loader
System.map-4.0.0-ck1-ARCH-Stephen-BFS
vmlinuz-4.0.0-ck1-ARCH-Stephen-BFS
vmlinuz-linux
vmlinuz-linux-lts
[stephen@Xen boot]$ 
[stephen@Xen boot]$ sudo ln -sf /boot/System.map-4.0.0-ck1-ARCH-Stephen-BFS /boot/System.map
[sudo] password for stephen: 
ln: failed to create symbolic link ‘./System.map’: Operation not permitted

I've tried logging as root and doing this but to no avail.

Has anyone got any ideas? The Kernel works fine but I'm told I should have the map file.

Last edited by Stevearch (2015-07-14 11:58:29)

Offline

#2 2015-07-14 12:09:45

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: Can't ln -s System.map file

/boot mounted as ro?
/boot is vfat?

Offline

#3 2015-07-14 12:13:01

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Awebb wrote:

/boot mounted as ro?
/boot is vfat?

Looks like its vfat -

[stephen@Xen ~]$ cat /etc/fstab 
# 
# /etc/fstab: static file system information
#
# <file system>	<dir>	<type>	<options>	<dump>	<pass>
# /dev/sda2
UUID=8b48f41b-b19a-47b9-9c9a-bdea6ecfd06b	/         	ext4      	rw,relatime,data=ordered	0 1

# /dev/sda1
UUID=D6AA-35EF      	/boot     	vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0 2

Anything I can do?

Offline

#4 2015-07-14 12:20:04

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: Can't ln -s System.map file

1. Use cp.
2. Is this still the same VM as in the other thread? Do you need the EFI boot or could you not simply use a different file system?
3. Am I right to assume, that you build your BFS kernel yourself anyway? Let the PKGBUILD do it.

Offline

#5 2015-07-14 12:25:05

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Awebb wrote:

1. Use cp.
2. Is this still the same VM as in the other thread? Do you need the EFI boot or could you not simply use a different file system?
3. Am I right to assume, that you build your BFS kernel yourself anyway? Let the PKGBUILD do it.

Thanks for getting back to me smile

>1. Use cp.
I guess that is the simplest solution for now.

>2. Is this still the same VM as in the other thread? Do you need the EFI boot or could you not simply use a different file system?
Yep same VM. I guess I don't need the EFI boot I just created it for experimenting. My other VM's use BIOS/MBR.

>3. Am I right to assume, that you build your BFS kernel yourself anyway? Let the PKGBUILD do it.
Yep I build it myself.
Can you clarify what you mean by 'Let the PKGBUILD do it.' ? smile

Offline

#6 2015-07-14 12:30:45

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: Can't ln -s System.map file

Forget what I said about the PKGBUILD. Is the file in /boot created by a makepkg target or do you copy it there manually?

As far as I understand, you don't need two files of the same kind. I'd wager the file with the kernel name symlinked to the map file is for easy switching between different maps. Many people test different kernel settings, it's easier to have them there with a name and symlink. I might be wrong, I'm no custom kernel expert.

Offline

#7 2015-07-14 12:47:22

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Awebb wrote:

Forget what I said about the PKGBUILD. Is the file in /boot created by a makepkg target or do you copy it there manually?

As far as I understand, you don't need two files of the same kind. I'd wager the file with the kernel name symlinked to the map file is for easy switching between different maps. Many people test different kernel settings, it's easier to have them there with a name and symlink. I might be wrong, I'm no custom kernel expert.

Thanks for the help man smile

Just out of curiosity - Does my /boot partition look correct to you?
It's been a while since i created this VM and going back and reading through the Beginners guide I can't see how /boot ended up as a VFAT.
I know you create the EFI partition and then format that as vfat

 mkfs.vfat -F32 /dev/sdxY 

But why would mounting that EFI partition make the entire /boot partition VFAT?

Am I missing something? sad

Offline

#8 2015-07-14 13:00:17

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: Can't ln -s System.map file

Now I think about it, there is no good reason for /boot to be vfat. Would you please lsblk and probably blkid (as root) to find out, what is what?

Offline

#9 2015-07-14 13:17:54

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,594

Re: Can't ln -s System.map file

Stevearch wrote:

But why would mounting that EFI partition make the entire /boot partition VFAT?(

Because the EFI system partition typically IS the boot partition.

Offline

#10 2015-07-14 13:37:47

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Scimmia wrote:
Stevearch wrote:

But why would mounting that EFI partition make the entire /boot partition VFAT?(

Because the EFI system partition typically IS the boot partition.

Thanks for replying Scimmia.

In theory - If I was to create a /Boot parition as EXT4 and then mount the EFI VFAT partition inside of it, would that work?
I'm just brain storming here.

Offline

#11 2015-07-14 13:38:13

bstaletic
Member
Registered: 2014-02-02
Posts: 658

Re: Can't ln -s System.map file

If your EFI system partition is /boot than it has to be vfat. vfat does not support symlinks. The kernel and map files are installed by "make install" which produces the names you have. To have it done automatically you would either have to patch the Makefile or PKGBUILD.

Offline

#12 2015-07-14 13:42:10

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,594

Re: Can't ln -s System.map file

How about this: Why do you want the system.map file in /boot?

Offline

#13 2015-07-14 13:50:35

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Scimmia wrote:

How about this: Why do you want the system.map file in /boot?

Hey,

Because the Arch Wiki said I should: https://wiki.archlinux.org/index.php/Ke … System.map

I've built my own Kernel btw, its not from the AUR.

Offline

#14 2015-07-14 13:54:50

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,594

Re: Can't ln -s System.map file

If you don't know why you want it there, you don't need it.

Offline

#15 2015-07-14 14:00:52

Stevearch
Member
From: North Wales
Registered: 2014-04-21
Posts: 80

Re: Can't ln -s System.map file

Hm, ok.

I just like to follow the Wiki to a tee, that way I have a solid log of what I did/didn't do in the event of a problem.

Thank you for your help smile

Offline

#16 2015-07-14 14:07:46

Awebb
Member
Registered: 2010-05-06
Posts: 6,298

Re: Can't ln -s System.map file

Scimmia wrote:
Stevearch wrote:

But why would mounting that EFI partition make the entire /boot partition VFAT?(

Because the EFI system partition typically IS the boot partition.

Is that so? I have never done that. The only scenario in which I would not refuse to do so is if there was only one Arch instance installed and nothing else. The moment you have a second Linux system installed, image names might collide. The moment I have Windows installed, is the moment I don't want my images to be on a file system Windows can read ootb.

Offline

#17 2015-07-14 14:14:12

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,594

Re: Can't ln -s System.map file

Awebb wrote:
Scimmia wrote:
Stevearch wrote:

But why would mounting that EFI partition make the entire /boot partition VFAT?(

Because the EFI system partition typically IS the boot partition.

Is that so? I have never done that. The only scenario in which I would not refuse to do so is if there was only one Arch instance installed and nothing else. The moment you have a second Linux system installed, image names might collide. The moment I have Windows installed, is the moment I don't want my images to be on a file system Windows can read ootb.

So you're keeping your kernel images outside the ESP? That eliminates the usage of many simple boot managers or direct loading with an NVRAM entry. Not worth the trade off.

Image name collisions are mostly theoretical from what I've seen. As for not having them on a FS Windows can read, why not?

Offline

Board footer

Powered by FluxBB