LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 683|回复: 2

命令错误么?

[复制链接]
发表于 2006-11-20 14:53:31 | 显示全部楼层 |阅读模式
[root@localhost jerry]# ifconfig
bash: ifconfig: command not found
这里命令也不对么?权限已经到root啦。
还有启动apache:/etc/init.d/apache restart么?为什么里面没有apache这个服务。
好郁闷哇~
还有最麻烦的就是,与外界的通讯不知道为什么老是中断~~~
我刚从Ubuntu转过来,不会有这么多的问题吧。
还有最麻烦的就是Xp启动不了。
[root@localhost jerry]# cat /boot/grub/menu.lst
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,6)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/hda
default=1
timeout=-1
splashimage=(hd0,6)/grub/splash.xpm.gz
hiddenmenu
title Fedora Core (2.6.18-1.2798.fc6)
        root (hd0,6)
        kernel /vmlinuz-2.6.18-1.2798.fc6 ro root=/dev/VolGroup00/LogVol00 rhgb quiet vga=791
        initrd /initrd-2.6.18-1.2798.fc6.img
title Windows XP
        rootnoverify (hd0,0)
        chainloader +1
这个应该没有问题吧。
[jerry@localhost ~]$ fdisk -l
bash: fdisk: command not found     这个命令也不能用么?????
[jerry@localhost ~]$ df
文件系统               1K-块        已用     可用 已用% 挂载点
/dev/mapper/VolGroup00-LogVol00
                       8951108    659196   7829884   8% /
/dev/hda7               147764     10770    129365   8% /boot
tmpfs                   253232         0    253232   0% /dev/shm
/dev/hda8              7236192   3959544   2903140  58% /usr
/dev/hda1              8225228   6925948   1299280  85% /c
/dev/hda5             10143120   9381000    762120  93% /d
/dev/hda6              2736374   2163804    572570  80% /e
不清楚是哪里出的问题。
发表于 2006-11-20 15:06:31 | 显示全部楼层
Fedora Core 中找不到命令的问题:

方法一,对单个用户有效:
$ gedit ~/.bashrc
在最后加入一行:
export PATH=${PATH}:/sbin:/usr/sbin:/usr/local/sbin


方法二,对所有用户有效:
$ su
# gedit /etc/profile
找到如下的内容:
>>>>>>>>>>>> 以下为文本内容 <<<<<<<<<<<<
# Path manipulation
if [ "$EUID" = "0" ]; then
        pathmunge /sbin
        pathmunge /usr/sbin
        pathmunge /usr/local/sbin
fi
>>>>>>>>>>>> 以上为文本内容 <<<<<<<<<<<<
改为(把 if, fi 开始的行注释掉):
>>>>>>>>>>>> 以下为文本内容 <<<<<<<<<<<<
# Path manipulation
# if [ "$EUID" = "0" ]; then
        pathmunge /sbin
        pathmunge /usr/sbin
        pathmunge /usr/local/sbin
# fi
>>>>>>>>>>>> 以上为文本内容 <<<<<<<<<<<<

保存退出,对于方法一,运行:
$ source ~/.bashrc
对于方法二,运行:
# source /etc/profile

打开新终端或下次登录时就起作用了。

apache
# service httpd start
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-11-20 15:47:47 | 显示全部楼层
为什么会出现这种问题呢~~~好郁闷哇~
不知道为什么偶的通讯老是要中断~
还有就是启动的问题。。。。
真的是昏头了。apache的服务是httpd……
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表