我正在运行 Ubuntu 12.04,并尝试armhf为 Jessie构建一个Debian 映像。我以前为 Wheezy 做过这件事。但是,如果目标是 Jessie,则 debootstap 脚本似乎不起作用。关于如何让它发挥作用的任何想法?
smachin@Ubuntu12_04_mq:~$ sudo debootstrap --arch=armhf --foreign $distro $targetdir
E: No such script: /usr/share/debootstrap/scripts/jessie
Run Code Online (Sandbox Code Playgroud) 我想使用 en_IL.UTF-8 语言环境 - 但我不能locale-gen。我可以选择这个值,/etc/default/locale但这对于所有应用程序来说显然是不够的。似乎我需要locale-gen为 en_IL.UTF-8 生成一些文件......我该怎么做?我还需要设置什么?
我需要在运行 Linux DL4100 发行版的 Western Digital DL4100 NAS 上安装 apt 软件包,其中唯一的软件包系统是dpkg. 为此,我必须安装 multiarch-support,这取决于libc6哪个取决于libgcc1. 但libgcc1pre 取决于multiarch-support.
光盘上没有包含yum, pacman, apt, aptitude, portage, dselect,emerge或其zypp名称的文件。我只dpkg在/var/lib/dpkg和 中找到/usr/bin/dpkg。
如何安装这些软件包,其中一个软件包依赖于另一个预先依赖于第一个软件包的软件包?
# dpkg -i /path/to/libc6.deb /path/to/multiarch-support.deb /path/to/libgcc1.deb
Run Code Online (Sandbox Code Playgroud)
返回
dpkg: package libgcc1 pre-depends on multiarch-support, which is not installed or flagged to be installed
Run Code Online (Sandbox Code Playgroud)
dpkg下没有安装包:
# dpkg -l
Name Version
+++-==============-==============
Run Code Online (Sandbox Code Playgroud) 我需要在某个文件夹中搜索最新创建的文件并 grep 模式的内容。到目前为止,我已经使用此命令取得了成功:
find /var/log/folder -type f -printf '%T+ %p\n' | sort | tail -n1 | xargs grep 'string to find'
Run Code Online (Sandbox Code Playgroud)
这确实找到了具有匹配项的最新文件,但我在标准输出中得到了意外的一行。
$ find /var/log/folder -type f -printf '%T+ %p\n' | sort | tail -n1 | xargs grep 'string to find'
grep: 2016-05-12+20:01:59.0570667340: No such file or directory
/var/log/folder/file:string to find
Run Code Online (Sandbox Code Playgroud)
如何更改我的命令,使其不给我“没有这样的文件或目录”行?
我正在尝试运行一个sudo apt-get update命令,我当前的发行版是 Debian Wheezy,当我尝试运行该命令时出现此错误:
W: Failed to fetch http://security.debian.org/dists/wheezy/updates/Release
Unable to find expected entry 'main/binary-mipsel/Packages' in Release file
(Wrong sources.list entry or malformed file)
Run Code Online (Sandbox Code Playgroud)
但是,当我查看sources.list文件时,它似乎没问题:
deb http://http.debian.net/debian wheezy main
deb-src http://http.debian.net/debian wheezy main
deb http://http.debian.net/debian wheezy-updates main
deb-src http://http.debian.net/debian wheezy-updates main
deb http://security.debian.org/ wheezy/updates main
deb-src http://security.debian.org/ wheezy/updates main
Run Code Online (Sandbox Code Playgroud) 我用 aptitude 删除了一些我不再需要的软件包。我很惊讶它们的依赖项都没有被自动删除(因为我认为 aptitude 与 apt-get 不同,默认情况下会这样做),所以我检查了这些依赖项,aptitude why并且所有这些依赖项都标有 status id,根据手册,这意味着“已安装,将被删除”。这什么时候会发生?我试图运行apt-get autoremove,aptitude upgrade,aptititude full-upgrade和apt-get dist-upgrade,和软件包仍然安装。此外,当我运行这些命令时,它们都会打印出0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.什么原因导致0 to remove包与标有状态的包之间存在差异id?
编辑:经过更多的挖掘,我发现所有这些包都被标记为手动安装,即使它们是自动安装的。我查看了我的历史记录,并注意到其中许多是使用 apt-get 而不是 aptitude 安装的,这可能是问题的一部分。我能够使用以下命令将它们全部删除:
# aptitude search "?installed" | grep "^id" | awk '{ print $2 }' | xargs apt-mark auto
# aptitude upgrade
Run Code Online (Sandbox Code Playgroud)
我仍然很好奇“d”状态到底是什么意思,以及 apt-get/aptitude 用它做什么,所以我把这个问题搁置了。
Linux有稳定的系统调用ABI,但NT没有,Windows只是确保Win32 ABI稳定,不会立即陷入内核空间。Windows 的较低级别功能(如 nt.dll)可能会在 Windows 更新或 Windows 版本之间发生变化。
我想知道对于其他内核,例如 FreeBSD 内核或 Mach,它们是否提供稳定的系统调用或仅提供 POSIX 接口的稳定 ABI?
我们如何锁定符号链接以使其无法被删除?
使用普通的文件/目录chattr +i /file/location可以实现这一点,但是使用符号链接来实现这一点,我们得到chattr: Operation not supported while reading flags on my-file。
还有一个类似的问题,如何为我的“/etc/resolv.conf”设置“chattr +i”?,但没有可以应用于此处的解决方案。
在Xfce中,我们可以按住Alt按键,使用鼠标左键移动窗口,或者使用鼠标右键调整窗口大小。同样,在elementary OS中也有该Super键,但是在GNOME中,如何设置该Super键来拖动或调整窗口大小?
I created a very simple C project and want to build a debian package from it.\nManually building the C project via the Makefile works as expected, it build the binary and can be installed in /usr/local/bin. When trying to build a debian packages however it fails with\ndh_usrlocal: error: debian/myhelloworld/usr/local/bin/myhelloworld is not a directory
The Makefile looks like this:
\nprefix = /usr/local/bin\n\nall: src/myhelloworld\n\nsrc/hello: src/myhelloworld.c\n @echo "CFLAGS=$(CFLAGS)" | \\\n fold -s -w 70 | \\\n sed -e 's/^/# /'\n …Run Code Online (Sandbox Code Playgroud)