Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
03-07-2005, 10:12 AM
|
#1
|
Member
Registered: Jul 2004
Location: Beijing, China
Distribution: Slackware,Redhat
Posts: 121
Rep:
|
how can I find the file belong to what pkg?
my distro is slackware 9.1.
a similar example:
rpm -qf /etc/inittab
can find /etc/inittab is part of initscripts-7.31.16.EL-1
thx for any help
|
|
|
03-07-2005, 10:17 AM
|
#2
|
Senior Member
Registered: Mar 2002
Location: Oklahoma
Posts: 1,154
Rep:
|
Code:
#
# inittab This file describes how the INIT process should set up
# the system in a certain run-level.
#
# Version: @(#)inittab 2.04 17/05/93 MvS
# 2.10 02/10/95 PV
# 3.00 02/06/1999 PV
# 4.00 04/10/2002 PV
#
# Author: Miquel van Smoorenburg, <miquels@drinkel.nl.mugnet.org>
# Modified by: Patrick J. Volkerding, <volkerdi@slackware.com>
#
# These are the default runlevels in Slackware:
# 0 = halt
# 1 = single user mode
# 2 = unused (but configured the same as runlevel 3)
# 3 = multiuser mode (default Slackware runlevel)
# 4 = X11 with KDM/GDM/XDM (session managers)
# 5 = unused (but configured the same as runlevel 3)
# 6 = reboot
# Default runlevel. (Do not set to 0 or 6)
id:4:initdefault:
# System initialization (runs when system boots).
si:S:sysinit:/etc/rc.d/rc.S
# Script to run when going single user (runlevel 1).
su:1S:wait:/etc/rc.d/rc.K
# Script to run when going multi user.
rc:2345:wait:/etc/rc.d/rc.M
# What to do at the "Three Finger Salute".
ca::ctrlaltdel:/sbin/shutdown -t5 -r now
# Runlevel 0 halts the system.
l0:0:wait:/etc/rc.d/rc.0
# Runlevel 6 reboots the system.
l6:6:wait:/etc/rc.d/rc.6
# What to do when power fails.
pf::powerfail:/sbin/genpowerfail start
# If power is back, cancel the running shutdown.
pg::powerokwait:/sbin/genpowerfail stop
# These are the standard console login getties in multiuser mode:
c1:1235:respawn:/sbin/agetty 38400 tty1 linux
c2:1235:respawn:/sbin/agetty 38400 tty2 linux
c3:1235:respawn:/sbin/agetty 38400 tty3 linux
c4:1235:respawn:/sbin/agetty 38400 tty4 linux
c5:1235:respawn:/sbin/agetty 38400 tty5 linux
c6:12345:respawn:/sbin/agetty 38400 tty6 linux
# Local serial lines:
#s1:12345:respawn:/sbin/agetty -L ttyS0 9600 vt100
#s2:12345:respawn:/sbin/agetty -L ttyS1 9600 vt100
# Dialup lines:
#d1:12345:respawn:/sbin/agetty -mt60 38400,19200,9600,2400,1200 ttyS0 vt100
#d2:12345:respawn:/sbin/agetty -mt60 38400,19200,9600,2400,1200 ttyS1 vt100
# Runlevel 4 used to be for an X window only system, until we discovered
# that it throws init into a loop that keeps your load avg at least 1 all
# the time. Thus, there is now one getty opened on tty6. Hopefully no one
# will notice. ;^)
# It might not be bad to have one text console anyway, in case something
# happens to X.
x1:4:wait:/etc/rc.d/rc.4
# End of /etc/inittab
|
|
|
03-07-2005, 10:20 AM
|
#3
|
Senior Member
Registered: Mar 2002
Location: Oklahoma
Posts: 1,154
Rep:
|
that should work, it is the inittab out of slackware-10.1 but the date shows it older than 9.1 so they should be the same, copy & paste it to a text file and give it the inittab name and save it in /etc and it should work...
if anyone knows this wont work please correct me on this idea...
|
|
|
03-07-2005, 10:46 AM
|
#4
|
Member
Registered: Jul 2004
Location: Beijing, China
Distribution: Slackware,Redhat
Posts: 121
Original Poster
Rep:
|
sorry! Okie
my english is bad.
I mean I wanna find a command that can find a file belong to what package
I can list a serial of files ownership of a slackware package by pkgtool.
but the other way round, I can't find a file belong to what package.
|
|
|
03-07-2005, 10:58 AM
|
#5
|
Senior Member
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783
Rep:
|
Re: how can I find the file belong to what pkg?
Quote:
Originally posted by jiawj
my distro is slackware 9.1.
a similar example:
rpm -qf /etc/inittab
can find /etc/inittab is part of initscripts-7.31.16.EL-1
thx for any help
|
Code:
skalkoto@darkstar:~$ grep "etc/inittab" -i /var/log/packages/*
/var/log/packages/sysvinit-2.84-i486-51:etc/inittab.new
skalkoto@darkstar:~$
*EDIT*
For every installed package in slackware there is a file in /var/log/packages with filename, the name of the package, that contains in pure text all the files that are contained in this package
Code:
skalkoto@darkstar:~$ cat /var/log/packages/sysvinit-2.84-i486-51
PACKAGE NAME: sysvinit-2.84-i486-51
COMPRESSED PACKAGE SIZE: 269 K
UNCOMPRESSED PACKAGE SIZE: 590 K
PACKAGE LOCATION: /mnt/cdrom/slackware/a/sysvinit-2.84-i486-51.tgz
PACKAGE DESCRIPTION:
sysvinit: sysvinit (init, the parent of all processes)
sysvinit:
sysvinit: System V style init programs by Miquel van Smoorenburg that control
sysvinit: the booting and shutdown of your system. These support a number of
sysvinit: system runlevels, each with a specific set of utilities spawned.
sysvinit: For example, the normal system runlevel is 3, which starts agetty
sysvinit: on virtual consoles tty1 - tty6. Runlevel 4 starts xdm.
sysvinit: Runlevel 0 shuts the system down.
sysvinit:
sysvinit:
sysvinit:
FILE LIST:
./
etc/
etc/rc.d/
etc/rc.d/rc.sysvinit.new
etc/rc.d/rc.local.new
etc/rc.d/rc.4.new
etc/rc.d/rc.6.new
etc/rc.d/rc.K.new
etc/rc.d/rc.M.new
etc/rc.d/rc.S.new
etc/inittab.new
usr/
usr/bin/
usr/bin/last
usr/doc/
usr/doc/sysvinit-2.84/
usr/doc/sysvinit-2.84/sysvinit-2.84.lsm
usr/doc/sysvinit-2.84/Install
usr/doc/sysvinit-2.84/Propaganda
usr/man/
usr/man/man1/
usr/man/man1/last.1.gz
usr/man/man5/
usr/man/man5/initscript.5.gz
usr/man/man5/inittab.5.gz
usr/man/man8/
usr/man/man8/runlevel.8.gz
usr/man/man8/killall5.8.gz
usr/man/man8/shutdown.8.gz
usr/man/man8/poweroff.8.gz
usr/man/man8/init.8.gz
usr/man/man8/halt.8.gz
usr/man/man8/pidof.8.gz
usr/man/man8/reboot.8.gz
usr/man/man8/telinit.8.gz
sbin/
sbin/halt
sbin/shutdown
sbin/killall5
sbin/runlevel
sbin/initscript.sample
sbin/init.new
install/
install/doinst.sh
install/slack-desc
skalkoto@darkstar:~$
Last edited by perfect_circle; 03-07-2005 at 11:04 AM.
|
|
|
03-07-2005, 11:11 AM
|
#6
|
Member
Registered: Jan 2005
Location: Dallas, TX
Distribution: Slackware-current
Posts: 248
Rep:
|
pkgtool
You can also use the pkgtool command to see what packages and directories are installed by each slackware package.
|
|
|
03-07-2005, 11:17 AM
|
#7
|
Member
Registered: Jul 2004
Location: Beijing, China
Distribution: Slackware,Redhat
Posts: 121
Original Poster
Rep:
|
thx perfect_circle
that a good ways and means
Last edited by jiawj; 03-07-2005 at 11:21 AM.
|
|
|
03-07-2005, 11:24 AM
|
#8
|
Senior Member
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783
Rep:
|
Re: pkgtool
Quote:
Originally posted by spaceballs
You can also use the pkgtool command to see what packages and directories are installed by each slackware package.
|
I don't think pkgtool is an option in this case. He wants to find, in which package inittab is, Unless you are recommending to search one-by-one all the installed packages to find the specific file.
|
|
|
03-07-2005, 12:55 PM
|
#9
|
Senior Member
Registered: Jun 2004
Location: Argentina (SR, LP)
Distribution: Slackware
Posts: 3,145
Rep:
|
A simple bash command (replace etc/inittab with any file):
Code:
grep -li "etc/inittab" /var/log/packages/*
You could also use http://slackware.com/pb you can search in a lot of ways there.
|
|
|
03-07-2005, 08:16 PM
|
#10
|
Member
Registered: Oct 2003
Location: Planet Earth
Distribution: Slackware, LFS
Posts: 561
Rep:
|
The file you want is MANIFEST.bz2. It's on the CDs in the slackware directory. It contains a complete list of every single file on a default slackware system, as well as the package that installed it.
|
|
|
All times are GMT -5. The time now is 12:10 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|