You are not logged in.

#1 2013-03-03 19:47:21

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

[SOLVED]Boot with Syslinux issue

Hello.
I gave a wrong command to delete everything in var/tmp or var/cache, I don't remember precisely. But after reboot syslinux was death.
It didn't find his configuration files, and I saw this message: "no default or ui configuration directive found". I tried to solve some issues, and in part I had success.
I copied this in boot/syslinux

hdt.c32	    syslinux.cfg  vesamenu.c32 chain.c32  ldlinux.sys	reboot.c32

and this is syslinux.cfg

# Config file for Syslinux -
# /boot/syslinux/syslinux.cfg
#
# Comboot modules:
#   * menu.c32 - provides a text menu
#   * vesamenu.c32 - provides a graphical menu
#   * chain.c32 - chainload MBRs, partition boot sectors, Windows bootloaders
#   * hdt.c32 - hardware detection tool
#   * reboot.c32 - reboots the system
#   * poweroff.com - shutdown the system
#
# To Use: Copy the respective files from /usr/lib/syslinux to /boot/syslinux.
# If /usr and /boot are on the same file system, symlink the files instead
# of copying them.
#
# If you do not use a menu, a 'boot:' prompt will be shown and the system
# will boot automatically after 5 seconds.
#
# Please review the wiki: https://wiki.archlinux.org/index.php/Syslinux
# The wiki provides further configuration examples

DEFAULT arch
PROMPT 0        # Set to 1 if you always want to display the boot: prompt 
TIMEOUT 50
# You can create syslinux keymaps with the keytab-lilo tool
#KBDMAP de.ktl

# Menu Configuration
# Either menu.c32 or vesamenu32.c32 must be copied to /boot/syslinux 
#UI menu.c32
UI vesamenu.c32

# Refer to http://syslinux.zytor.com/wiki/index.php/Doc/menu
MENU TITLE Arch Linux
#MENU BACKGROUND splash.png
MENU COLOR border       30;44   #40ffffff #a0000000 std
MENU COLOR title        1;36;44 #9033ccff #a0000000 std
MENU COLOR sel          7;37;40 #e0ffffff #20ffffff all
MENU COLOR unsel        37;44   #50ffffff #a0000000 std
MENU COLOR help         37;40   #c0ffffff #a0000000 std
MENU COLOR timeout_msg  37;40   #80ffffff #00000000 std
MENU COLOR timeout      1;37;40 #c0ffffff #00000000 std
MENU COLOR msg07        37;40   #90ffffff #a0000000 std
MENU COLOR tabmsg       31;40   #30ffffff #00000000 std

# boot sections follow
#
# TIP: If you want a 1024x768 framebuffer, add "vga=773" to your kernel line.
#
#-*

LABEL arch
	MENU LABEL Arch Linux
	LINUX ../vmlinuz-linux
	APPEND root=/dev/sda7 ro
	INITRD ../initramfs-linux.img

LABEL archfallback
	MENU LABEL Arch Linux Fallback
	LINUX ../vmlinuz-linux
	APPEND root=/dev/sda3 ro
	INITRD ../initramfs-linux-fallback.img

LABEL windows
        MENU LABEL Windows
        COM32 chain.c32
        APPEND hd0 1

LABEL hdt
        MENU LABEL HDT (Hardware Detection Tool)
        COM32 hdt.c32
 
LABEL reboot
        MENU LABEL Reboot
        COM32 reboot.c32
 
LABEL off
        MENU LABEL Power Off
        COMBOOT poweroff.com

I think I forgot something, because Arch Linux and its fallback don't boot. When I click one of them, the only effect is the cooldown's restart. But the others labels work correctly.
What's wrong?
Anyway I wish you a nice day.
Regards, Grant.

Last edited by Grant (2013-03-06 20:56:06)

Offline

#2 2013-03-03 19:54:10

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

Re: [SOLVED]Boot with Syslinux issue

What all did you delete? Is the kernel and initrd even on boot anymore?

You're referencing a different root partition for fallback than you are for the normal boot, is that right?

Offline

#3 2013-03-03 19:56:30

elkoraco
Member
Registered: 2013-02-18
Posts: 140

Re: [SOLVED]Boot with Syslinux issue

Do you know how to chroot into the system from a Live CD? The Arch install medium will do.

Offline

#4 2013-03-03 20:27:35

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED]Boot with Syslinux issue

Yeah, /dev/sda7 or /dev/sda3? Which one is it?

Syslinux counts BIOS drives from zero and partitions from one. I suggest that you use UUIDs instead of names assigned by the kernel ("sdx"), so that your "sda7" doesn't become "sdb7" when you have a bootable USB stick inserted while you start your computer.

To use UUIDs, see the example from here: https://wiki.archlinux.org/index.php/Sy … sic_Config

Last edited by DSpider (2013-03-03 20:29:11)


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#5 2013-03-03 20:33:02

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

/ is in /dev/sda7. I'm sure.
For the fallback kernel, /dev/sda3 is from default, because I didn't know what I had to set.
But I would to know why deleting something in /var is related with syslinux. I think it is the same configuration as before.
How can I check if the kernel is still there?

Last edited by Grant (2013-03-03 20:35:16)

Offline

#6 2013-03-03 20:37:10

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

elkoraco wrote:

Do you know how to chroot into the system from a Live CD? The Arch install medium will do.

Nope, I don't know what's that.

Offline

#7 2013-03-03 20:47:45

flipper T
Member
Registered: 2012-09-14
Posts: 419

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:
elkoraco wrote:

Do you know how to chroot into the system from a Live CD? The Arch install medium will do.

Nope, I don't know what's that.

Do you know how to search arch's wiki ?


If I'm curt with you it's because time is a factor. I think fast, I talk fast and I need you guys to act fast if you wanna get out of this. So, pretty please... with sugar on top. Clean the [censored] car. -The Wolf

Offline

#8 2013-03-04 08:24:18

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

Nope, I don't know what's that.

https://wiki.archlinux.org/index.php/Chroot

Don't forget to establish an internet connection first. Then reinstall the linux package (the kernel), which will re-generate new initramfs images (regular and fallback), and then reinstall Syslinux according to the instructions from the Beginners' Guide.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#9 2013-03-04 12:38:14

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

Please wait a moment. I haven't told that the kernel was deleted. I don't believe it, because shouldn't have any sense.
But if I've deleted the kernel, I will have to reinstall Arch?

Last edited by Grant (2013-03-04 13:39:10)

Offline

#10 2013-03-04 12:54:33

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,571
Website

Re: [SOLVED]Boot with Syslinux issue

The command that you "don't remember precisely" clearly did more than what you intended.  Syslinux's configs are not in /var/.  You've somehow removed many other files that you did not intend to delete.

There's certainly no need to poke at someone for making a mistake, but if you are in denial of making any mistake then what are we doing here?  You f*(&@ed something up, accept it and start fixing.

What are the current contents of /boot/syslinux and /boot?

If you deleted the kernel you will not need to "reinstall arch", but you will need to reinstall the kernel (e.g., `pacstrap /mnt linux` from a live environment).

Last edited by Trilby (2013-03-04 12:55:20)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#11 2013-03-04 13:14:06

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

In .bash_history should there are every commands I gave in the shell. I will go to see it.
@Trilby
In boot/syslinux there are these files:

hdt.c32	    syslinux.cfg  vesamenu.c32 chain.c32  ldlinux.sys	reboot.c32

as said in the first post.
Where should be located the kernel?

Offline

#12 2013-03-04 13:15:04

qinohe
Member
From: Netherlands
Registered: 2012-06-20
Posts: 1,601

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

Please wait a moment. I haven't told that was kernel was deleted. I don't believe it, because shouldn't have any sense.
But if I've deleted the kernel, I will have to reinstall Arch?

Hi, no one is suggesting you to reinstall the kernel,or whatever, but... you need to educate yourself about some things!
Chroot is suggested, it lets you change your root, as it says.)
By learning chroot, you can troubleshout and repair virtually everething, like reinstalling your kernel or syslinux, or install a package, edit a file, or check what last command you used and share with us...
The list goes on of course, but to give you an idea, hope this helps...)

Offline

#13 2013-03-04 13:53:23

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

qinohe wrote:
Grant wrote:

Please wait a moment. I haven't told that was kernel was deleted. I don't believe it, because shouldn't have any sense.
But if I've deleted the kernel, I will have to reinstall Arch?

check what last command you used and share with us...

What? If it's true, please tell me how.
I don't find any connection with chroot.

Last edited by Grant (2013-03-04 13:53:51)

Offline

#14 2013-03-04 14:06:43

qinohe
Member
From: Netherlands
Registered: 2012-06-20
Posts: 1,601

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

What? If it's true, please tell me how.
I don't find any connection with chroot.

Well if you have chroot access, you can check your history !
What do you mean, you don't find connection with chroot??

Offline

#15 2013-03-04 14:52:56

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

Where should be located the kernel?

It's in /boot. You should be seeing something like this (from a LiveCD):

# mount /dev/sda7 /mnt
# ls -lh /mnt/boot
total 40M
-rw-r--r-- 1 root root  14M Feb 27 08:09 initramfs-linux-fallback.img
-rw-r--r-- 1 root root 3.6M Feb 27 08:09 initramfs-linux.img
-rw-r--r-- 1 root root  13M Feb 19 20:14 initramfs-linux-lts-fallback.img
-rw-r--r-- 1 root root 3.6M Feb 19 20:14 initramfs-linux-lts.img
drwxr-xr-x 2 root root 4.0K Oct 30 00:40 syslinux
-rw-r--r-- 1 root root 3.4M Feb 25 13:32 vmlinuz-linux
-rw-r--r-- 1 root root 3.0M Feb 18 02:54 vmlinuz-linux-lts

Here, "vmlinuz-linux" is the kernel (~3 MB). Scimmia and Trilby have already asked you about the contents of this folder (/boot), because if you have a separate boot partition and you don't respect the mounting order (e.g. by mounting the boot partition before the root partition - which is INCORRECT), then the files won't show up, or you may have a "boot" folder on the separate boot partition, and you'll end up with "/boot/boot/syslinux" scenarios. Then of course that the menu entries wouldn't work; because they're pointing to the wrong location!

Do you have a separate boot partition?


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#16 2013-03-04 15:46:38

s1ln7m4s7r
Member
Registered: 2013-02-22
Posts: 262

Re: [SOLVED]Boot with Syslinux issue

You say you cant chroot into your system.

maybe you bypassed a step.

 - boot arch install disk
 - mount your system partitions under /mnt (remember to mount all partitions if you have separate ones
 for /boot, etc, in /mnt/boot, /mnt/etc)
 - arch-chroot /mnt

then you can work to fix your problems

Offline

#17 2013-03-04 15:52:13

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

DSpider wrote:
Grant wrote:

Where should be located the kernel?

It's in /boot. You should be seeing something like this (from a LiveCD):

# mount /dev/sda7 /mnt
# ls -lh /mnt/boot
total 40M
-rw-r--r-- 1 root root  14M Feb 27 08:09 initramfs-linux-fallback.img
-rw-r--r-- 1 root root 3.6M Feb 27 08:09 initramfs-linux.img
-rw-r--r-- 1 root root  13M Feb 19 20:14 initramfs-linux-lts-fallback.img
-rw-r--r-- 1 root root 3.6M Feb 19 20:14 initramfs-linux-lts.img
drwxr-xr-x 2 root root 4.0K Oct 30 00:40 syslinux
-rw-r--r-- 1 root root 3.4M Feb 25 13:32 vmlinuz-linux
-rw-r--r-- 1 root root 3.0M Feb 18 02:54 vmlinuz-linux-lts

Here, "vmlinuz-linux" is the kernel (~3 MB). Scimmia and Trilby have already asked you about the contents of this folder (/boot), because if you have a separate boot partition and you don't respect the mounting order (e.g. by mounting the boot partition before the root partition - which is INCORRECT), then the files won't show up, or you may have a "boot" folder on the separate boot partition, and you'll end up with "/boot/boot/syslinux" scenarios. Then of course that the menu entries wouldn't work; because they're pointing to the wrong location!

Do you have a separate boot partition?

No, I don't have a separate boot partition. And this is the sad contenent of /mnt/boot:

total 4.0K
drwxr-xr-x 2 root root 4.0K Mar  3 20:24 syslinux/

And so, precisely, what I have to do?

Last edited by Grant (2013-03-04 15:52:39)

Offline

#18 2013-03-04 16:07:33

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED]Boot with Syslinux issue

I already said what you have to do.

DSpider wrote:

https://wiki.archlinux.org/index.php/Chroot

Don't forget to establish an internet connection first. Then reinstall the linux package (the kernel), which will re-generate new initramfs images (regular and fallback), and then reinstall Syslinux according to the instructions from the Beginners' Guide.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#19 2013-03-04 18:02:36

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

I try with only

pacstrap /mnt linux && makepkg -g

or with these: https://wiki.archlinux.org/index.php/Be … ase_system ?

Offline

#20 2013-03-04 23:45:26

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,198

Re: [SOLVED]Boot with Syslinux issue

Why would you add "makepkg -g"? Trilby gave you the command as "pacstrap /mnt linux".

If you tell us which commands you *actually* used by looking in your history file (or root's as applicable), then it will be possible to say what you need to do. It is clear from the contents of /mnt/boot , however, that you *at least* need to reinstall the kernel. Trilby's command will do precisely that.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#21 2013-03-05 14:00:38

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

I would to say mkinitcpio, not makepkg. Anyway I tried to use /pacstrap /mnt linux, but it has only reinstalled the kernel, because was already installed.
After I went in /mnt/boot/syslinux to see if there was the kernel's images, but there was only the vmlinux image.
Here's the contenent:

syslinux/  vmlinuz-linux

Infact trying to boot it warn me that it can't find the initramfs image. I think that error is correlated with the pacstrap's output:

==> Creating install root at /mnt
==> Installing packages to /mnt
:: Synchronizing package databases...
 core is up to date
 extra is up to date
 community is up to date
resolving dependencies...
looking for inter-conflicts...

Targets (1): linux-3.7.9-2

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

Proceed with installation? [Y/n] 
checking package integrity...
loading package files...
checking for file conflicts...
checking available disk space...
upgrading linux...
call to execv failed (No such file or directory)
error: command failed to execute correctly

and so pacman can't run mkinitcpio. Sfortunately, in both history (root and my user) there wasn't the command. I can tell you something more about it: after that command (that I killed after some time, don't rembember why) systemctl reboot (or poweroff) don't go, and I had to reboot my computer manually, using the restart button.

Offline

#22 2013-03-05 16:23:55

s1ln7m4s7r
Member
Registered: 2013-02-22
Posts: 262

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

I would to say mkinitcpio, not makepkg. Anyway I tried to use /pacstrap /mnt linux, but it has only reinstalled the kernel, because was already installed.
After I went in /mnt/boot/syslinux to see if there was the kernel's images, but there was only the vmlinux image.
Here's the contenent:

syslinux/  vmlinuz-linux

Infact trying to boot it warn me that it can't find the initramfs image. I think that error is correlated with the pacstrap's output:

==> Creating install root at /mnt
==> Installing packages to /mnt
:: Synchronizing package databases...
 core is up to date
 extra is up to date
 community is up to date
resolving dependencies...
looking for inter-conflicts...

Targets (1): linux-3.7.9-2

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

Proceed with installation? [Y/n] 
checking package integrity...
loading package files...
checking for file conflicts...
checking available disk space...
upgrading linux...
call to execv failed (No such file or directory)
error: command failed to execute correctly

and so pacman can't run mkinitcpio. Sfortunately, in both history (root and my user) there wasn't the command. I can tell you something more about it: after that command (that I killed after some time, don't rembember why) systemctl reboot (or poweroff) don't go, and I had to reboot my computer manually, using the restart button.

It wont work because you dont have the files that would came with mkinitcpio package. So it cant create the initramfs. If you cant run pacstrap /mnt mkinitcpio directlly then try chroot into your system and install it thrue pacman itself pacman -S mkinitcpio.

I think also that you may havê deleted much more than just your kernel files. If nothing else works then try reinstalling the base group. And then reedit your system files. and recreate initramfs.

Offline

#23 2013-03-05 19:30:22

Grant
Member
From: Italy
Registered: 2012-12-15
Posts: 246

Re: [SOLVED]Boot with Syslinux issue

I did a lot of things, and the kernel boots. But there's an error:

Failed to start Recreate Volatile Files and Directories.
See 'systemctl status systemd-tmpfiles-setup.service' for details. 

Another thing: it's normal that I don't have /etc/hostname? Or I must use hostnamectl?

Last edited by Grant (2013-03-05 19:30:37)

Offline

#24 2013-03-05 21:14:30

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED]Boot with Syslinux issue

I think pacstrap was supposed to generate them for you. Or maybe it just doesn't work that way and it only grabbed and deployed the linux package. Hmmm... Chroot and re-generate new initramfs images with:

# mkinitcpio -p linux

At least Syslinux is installed correctly. Next time, instead of deleting random shit, move them somewhere else or at least rename them with a ".bak" extension - short for backup.

Last edited by DSpider (2013-03-05 21:16:30)


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#25 2013-03-05 21:47:26

s1ln7m4s7r
Member
Registered: 2013-02-22
Posts: 262

Re: [SOLVED]Boot with Syslinux issue

Grant wrote:

I did a lot of things, and the kernel boots. But there's an error:

Failed to start Recreate Volatile Files and Directories.
See 'systemctl status systemd-tmpfiles-setup.service' for details. 

Post what you get from systemctl status systemd-tmpfiles-setup.service if you wan't more help about that!

Also check this:
http://forums.fedoraforum.org/showthread.php?t=283902

Another thing: it's normal that I don't have /etc/hostname? Or I must use hostnamectl?

Yes t's normal, you need to create it, then reboot!

echo name_of_your_host > /etc/hostname

Last edited by s1ln7m4s7r (2013-03-05 21:50:23)

Offline

Board footer

Powered by FluxBB