【问题标题】:Tomatousb, ls command is broken and returns just the queryTomatousb, ls 命令坏了,只返回查询
【发布时间】:2018-07-11 01:36:48
【问题描述】:

我在旧的tomatousb 上进行了ipkg 升级,这似乎至少导致ls 命令损坏:

  [root@tomatousb root]$ /bin/ls /
   /
  [root@tomatousb root]$ ls /bin
   /bin

但是,结果以不同的颜色显示。 还有奇怪的行为:

   [root@tomatousb root]$ echo $PATH
   echo $PATH
   sh: echo: Permission denied

   [root@tomatousb root]$ /bin/echo $PATH
   /bin/echo $PATH
   /opt/bin:/opt/sbin:/bin:/sbin:/usr/bin:/usr/sbin

我没有胶水有什么问题。 我看到的日志如下:

 /var/log/messages
 Jan  1 04:00:11 tomatousb user.info kernel: ipt_recent v0.3.1: Stephen Frost <sfrost@snowman.net>.  http://snowman.net/projects/ipt_recent/
 Jan 31 23:10:21 tomatousb user.notice root: <<<< MPCSD: Config-files not found in /jffs/config/mpcs & /opt/etc/mpcs!!! Exit. >>>>
 Jan 31 23:11:02 tomatousb cron.err crond[143]: time disparity of 25290430 minutes detected
 Jan 31 23:37:26 tomatousb authpriv.info dropbear[505]: Child connection from *.*.*.*:*

所以,基本上,当我使用 SSH 时,我会使用 dropbear。 似乎在上一次 ipkg 升级期间,我得到了新的 bash、tcpdump 和另外两个项目,但我不记得具体是哪一个。而且我找不到 ipkg 日志文件...

【问题讨论】:

  • 看起来与编程无关,您应该在 superuser.com 或 serverfault.com 等更具体的论坛中尝试您的问题。

标签: bash ls dropbear


【解决方案1】:

当我在同一个盒子上遇到同样的问题时,我终于碰到了自己的旧讨论,原因如下:

    [root@tomatousb mnt]$ cat /opt/etc/profile
    #
    # Bash initialization script
    #

    PS1="[\u@\h \W]$ "
    PATH=/opt/sbin:/opt/bin:/sbin:/bin:/usr/sbin:/usr/bin
    LD_LIBRARY_PATH=/opt/lib:${LD_LIBRARY_PATH}

    export PS1 PATH LD_LIBRARY_PATH
    [root@tomatousb mnt]$ rm /opt/etc/profile

然后我重新启动,一切恢复正常运行! 不知道该配置文件中究竟是什么破坏了一切并在运行 vi 时导致“内存耗尽”错误。

【讨论】:

    猜你喜欢
    • 2013-10-22
    • 1970-01-01
    • 1970-01-01
    • 2014-04-16
    • 2023-03-19
    • 2023-01-03
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多