Компьютерный форум OSzone.net  

Компьютерный форум OSzone.net (http://forum.oszone.net/index.php)
-   Общий по FreeBSD (http://forum.oszone.net/forumdisplay.php?f=10)
-   -   Конфигурирование ядра (http://forum.oszone.net/showthread.php?t=134686)

Fet 14-03-2009 01:33 1063237

Конфигурирование ядра
 
На днях установил собственное ядро, удалил все ненужные устройства опираясь на файл dmesg.boot. Так вот во время конфигурирования файла ядра я в GENERIC не нашол свой cd дисковод "acd" к тому же ядро после установки не запустилось выдавая в общем что то на счет монтирования filesystem. Как мне это все организовать чтоб все работало?

z01 14-03-2009 02:05 1063251

в загрузчик прописали?

leonty 14-03-2009 11:16 1063385

Fet, нужно посмотреть на конфиг твоего ядра.
И собщени вида
Цитата:

Цитата Fet
в общем что то на счет монтирования filesystem »

не катируются. Либо ошибку полностью. Либо гадать на кофейной гуще никто не будет.

Fet 14-03-2009 13:31 1063496

Цитата:

Цитата z01
в загрузчик прописали?

нет, а как?
Цитата:

Цитата leonty
Fet, нужно посмотреть на конфиг твоего ядра.
И собщени вида

Цитата:

Цитата Сообщение
Manual root filesystem specification:
Mount <device> using file system <fstype> eg. ufs: da0s1a
List valid disk boot devices.
Abort manual input.
mount root>

Ядро
Код:

#
# GENERIC -- Generic kernel configuration file for FreeBSD/i386
#
# For more information on this file, please read the handbook section on
# Kernel Configuration Files:
#
#    http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
#
# The handbook is also available locally in /usr/share/doc/handbook
# if you've installed the doc distribution, otherwise always see the
# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
# latest information.
#
# An exhaustive list of options and more detailed explanations of the
# device lines is also present in the ../../conf/NOTES and NOTES files.
# If you are in doubt as to the purpose or necessity of a line, check first
# in NOTES.
#
# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.474.2.15.2.1 2008/11/25 02:59:29 kensmith Exp $

cpu                I686_CPU
ident                KERNEL

# To statically compile in device wiring instead of /boot/device.hints
#hints                "GENERIC.hints"                # Default places to look for devices.

makeoptions        DEBUG=-g                # Build kernel with gdb(1) debug symbols

options        SCHED_ULE                # ULE scheduler
options        PREEMPTION                # Enable kernel thread preemption
options        INET                        # InterNETworking
options        INET6                        # IPv6 communications protocols
options        SCTP                        # Stream Control Transmission Protocol
options        FFS                        # Berkeley Fast Filesystem
options        SOFTUPDATES                # Enable FFS soft updates support
options        UFS_ACL                        # Support for access control lists
#options        UFS_DIRHASH                # Improve performance on big directories
options        UFS_GJOURNAL                # Enable gjournal-based UFS journaling
options        MD_ROOT                        # MD is a potential root device
options        NFSCLIENT                # Network Filesystem Client
options        NFSSERVER                # Network Filesystem Server
options        NFSLOCKD                # Network Lock Manager
options        NFS_ROOT                # NFS usable as /, requires NFSCLIENT
options        MSDOSFS                        # MSDOS Filesystem
options        CD9660                        # ISO 9660 Filesystem
#options        PROCFS                        # Process filesystem (requires PSEUDOFS)
#options        PSEUDOFS                # Pseudo-filesystem framework
options        GEOM_PART_GPT                # GUID Partition Tables.
options        GEOM_LABEL                # Provides labelization
options        COMPAT_43TTY                # BSD 4.3 TTY compat [KEEP THIS!]
options        COMPAT_FREEBSD4                # Compatible with FreeBSD4
options        COMPAT_FREEBSD5                # Compatible with FreeBSD5
options        COMPAT_FREEBSD6                # Compatible with FreeBSD6
options        SCSI_DELAY=5000                # Delay (in ms) before probing SCSI
options        KTRACE                        # ktrace(1) support
options        STACK                        # stack(9) support
options        SYSVSHM                        # SYSV-style shared memory
options        SYSVMSG                        # SYSV-style message queues
options        SYSVSEM                        # SYSV-style semaphores
options        _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
options        KBD_INSTALL_CDEV        # install a CDEV entry in /dev
options        ADAPTIVE_GIANT                # Giant mutex is adaptive.
options        STOP_NMI                # Stop CPUS using NMI instead of IPI
options        AUDIT                        # Security event auditing
#options        KDTRACE_HOOKS                # Kernel DTrace hooks

# To make an SMP kernel, the next two lines are needed
options        SMP                        # Symmetric MultiProcessor Kernel
device                apic                        # I/O APIC

# MY OPTIONS
options                IPFILTER_LOG

# CPU frequency control
#device                cpufreq

# Bus support.
#device                eisa
device                pci

# Floppy drives
device                fdc

# ATA and ATAPI devices
device                ata
#device                atadisk                # ATA disk drives
#device                ataraid                # ATA RAID drives

#device                atapifd                # ATAPI floppy drives
#device                atapist                # ATAPI tape drives
options        ATA_STATIC_ID        # Static device numbering

# SCSI Controllers
#device                ahb                # EISA AHA1742 family
#device                ahc                # AHA2940 and onboard AIC7xxx devices
options        AHC_REG_PRETTY_PRINT        # Print register bitfields in debug
                                        # output.  Adds ~128k to driver.
#device                ahd                # AHA39320/29320 and onboard AIC79xx devices
#options        AHD_REG_PRETTY_PRINT        # Print register bitfields in debug
                                        # output.  Adds ~215k to driver.
#device                amd                # AMD 53C974 (Tekram DC-390(T))
#device                hptiop                # Highpoint RocketRaid 3xxx series
#device                isp                # Qlogic family
#device        ispfw                # Firmware for QLogic HBAs- normally a module
#device                mpt                # LSI-Logic MPT-Fusion
#device                ncr                # NCR/Symbios Logic
#device                sym                # NCR/Symbios Logic (newer chipsets + those of `ncr')
#device                trm                # Tekram DC395U/UW/F DC315U adapters

#device                adv                # Advansys SCSI adapters
#device                adw                # Advansys wide SCSI adapters
#device                aha                # Adaptec 154x SCSI adapters
#device                aic                # Adaptec 15[012]x SCSI adapters, AIC-6[23]60.
#device                bt                # Buslogic/Mylex MultiMaster SCSI adapters

#device                ncv                # NCR 53C500
#device                nsp                # Workbit Ninja SCSI-3
#device                stg                # TMC 18C30/18C50

# SCSI peripherals
#device                scbus                # SCSI bus (required for SCSI)
#device                ch                # SCSI media changers
#device                da                # Direct Access (disks)
#device                sa                # Sequential Access (tape etc)
#device                cd                # CD

# RAID controllers interfaced to the SCSI subsystem


# RAID controllers

# atkbdc0 controls both the keyboard and the PS/2 mouse
device                atkbdc                # AT keyboard controller
device                atkbd                # AT keyboard
device                psm                # PS/2 mouse

device                kbdmux                # keyboard multiplexer

device                vga                # VGA video card driver

device                splash                # Splash screen and screen saver support

# syscons is the default console driver, resembling an SCO console
device                sc

device                agp                # support several AGP chipsets

# Power management support (see NOTES for more options)
#device                apm
# Add suspend/resume support for the i8254.
device                pmtimer

# PCCARD (PCMCIA) support
# PCMCIA and cardbus bridge support


# Serial (COM) ports
device                sio                # 8250, 16[45]50 based serial ports


# Parallel port
device                ppc
device                ppbus                # Parallel port bus (required)
device                lpt                # Printer
device                plip                # TCP/IP over parallel
device                ppi                # Parallel port interface device
#device                vpo                # Requires scbus and da

# If you've got a "dumb" serial or parallel PCI card that is
# supported by the puc(4) glue driver, uncomment the following
# line to enable it (connects to sio, uart and/or ppc drivers):
#device                puc

# PCI Ethernet NICs.


# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
device                miibus                # MII bus support

#device                ale                # Atheros AR8121/AR8113/AR8114 Ethernet

device                vr                # VIA Rhine, Rhine II


# ISA Ethernet NICs.  pccard NICs included.

# 'device ed' requires 'device miibus'

# Wireless NIC cards

device                ath_hal                # Atheros HAL (Hardware Access Layer)


# Pseudo devices.
device                loop                # Network loopback

device                ether                # Ethernet support


device                tun                # Packet tunnel.
device                pty                # Pseudo-ttys (telnet etc)
device                md                # Memory "disks"

device                faith                # IPv6-to-IPv4 relaying (translation)


# The `bpf' device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
# Note that 'bpf' is required for DHCP.
device                bpf                # Berkeley packet filter

# USB support

device                ohci                # OHCI PCI->USB interface

device                usb                # USB Bus (required)
#device                udbp                # USB Double Bulk Pipe devices


leonty 14-03-2009 20:46 1063948

Fet, грузись с лайвсд. смотри как определяется в системе хдд и как он прописан в fstab'е

Fet 15-03-2009 11:59 1064366

Почему с лайвсд?

leonty 15-03-2009 12:08 1064372

Цитата:

Цитата Fet
Почему с лайвсд? »

ну я так понимаю система у тебя вообще не должна грузиться, сам же написал
Цитата:

Цитата Fet
Manual root filesystem specification:
Mount <device> using file system <fstype> eg. ufs: da0s1a
List valid disk boot devices.
Abort manual input.
mount root> »


dmitryst 15-03-2009 20:33 1064829

Цитата:

Если загрузка нового ядра не получилась (такое тоже возможно), вы можете загрузиться со старым ядром. Для этого, в начале загрузки на подсказку Boot: надо быстро сказать kernel.old. Естественно, после этого надо снова вернуться к редактированию вашей конфигурации и повторить все последующие пункты.

Только не торопитесь. Если новое ядро опять окажется неработоспособным, вы можете попасть в неприятную ситуацию, так как после очередной инсталляции ядра командой make install получится:

kernel.old - предыдущая неработающая версия ядра

kernel - новая, но столь же бесполезная.

Но даже теперь не отчаивайтесь. У вас должен был остаться в корневой директории файл kernel.GENERIC и вы можете всегда загрузить его (конечно, если вы не удалили его ранее в целях экономии места на диске). Поэтому на подсказку Boot: надо набрать kernel. GENERIC.

Для того, чтобы не попасть в вышеописанную ситуацию, после загрузки старого ядра, замените им ваше новое ядро:

# cd /
# chflags noschg kernel
# cp kernel kernel.new
# cp kernel.old kernel
# chflags schg kernel
# reboot

После этого можете смело продолжать ваши изыскания по конфигурированию ядра.
взял тут

WhitePangolin 16-03-2009 14:56 1065458

Зачем такие сложности?
Зашел в сингл моде, система ругнется на то, что не смогла определить файловую систему, жмакаем скрол, пролистываем вверх экран, находим как инициализировались жесткие диски, монтируем вручную, переписываем fstab ребутаемся, и все.

p.s.
А отвалилось потому что PROCFS закоментил, у меня такая же трабла была.

leonty 16-03-2009 19:39 1065732

можно и так (:
наверное так будет даже проще.

Fet 16-03-2009 19:40 1065734

leonty, как сказал "Штатный телепат" (dmitryst), который правильно определил мою мысль:) можно загрузить и старое ядро.


Время: 17:15.

Время: 17:15.
© OSzone.net 2001-