Showing posts with label Debian/Ubuntu. Show all posts
Showing posts with label Debian/Ubuntu. Show all posts

2009-04-15

Give up OS X on iBook G4

OS X 系统的不 open 导致的痛苦由来已久,早有心意弃之,一直未下决心。现苹果已转投 Intel,放弃 PowerPC,天晓得我的 iBook 还能支持到什么时候?干脆先苹果一步,主动抛弃 OS X,换成了 Debian 5(code named Lenny)。

2009-04-07

Valgrind for PowerPC on Debian

$ valgrind ./invalid_free
valgrind: Fatal error at startup: a function redirection
valgrind: which is mandatory for this platform-tool combination
valgrind: cannot be set up. Details of the redirection are:
valgrind:
valgrind: A must-be-redirected function
valgrind: whose name matches the pattern: strlen
valgrind: in an object with soname matching: ld.so.1
valgrind: was not found whilst processing
valgrind: symbols from the object with soname: ld.so.1
valgrind:
valgrind: Possible fix: install glibc's debuginfo package on this machine.
valgrind:
valgrind: Cannot continue -- exiting now. Sorry.
$ aptitude install libc-dbg

2008-10-28

Install Ubuntu 8.04 from Hard Disk

  • Make an ISO file ubuntu804.iso from Ubuntu's LiveCD (8.04 desktop), put the ISO file in D:/ubuntu804.iso
  • Mount the ISO file or the LiveCD, copy two files CDROM:/casper/{initrd.gz,vmlinuz} to Windows drive D:/
  • Download grub4dos, extract its files to C:/
  • Edit C:/boot.ini, add one new line: C:\grldr="GRUB4DOS"
  • Edit C:/menu.lst
    title Find and Install Ubuntu
    find --set-root /ubuntu804.iso
    kernel /vmlinuz boot=casper iso-scan/filename=/ubuntu804.iso
    initrd /initrd.gz
  • Reboot Windows XP
  • Select GRUB4DOS from the boot menu
  • ... ...
  • Will boot to the same screen as if you're directly booting from the LiveCD.

2008-10-13

See full screen man pages on Fedora Core 3

ubuntu 6.06 上看 man pages 的时候能全屏显示, 但 Fedora 3 上却不能, 研究一番, 可以自己编译 man-db 来解决:

编译 man-db 可能需要依赖 gdbm-devel 或者 db4-devel (ubuntu 上对应 libgdbm-dev 或者 libdb-dev).

2008-06-25

PIDs Littler Than 300 Reserved?

在 ubuntu 6.06.2 上试验了一下, pid 长到 32767 之后, 新的 pid 并不是从 1 开始分配的, 而是从 300 开始, 貌似系统给自己预留了一些 :-)

2008-06-13

[Ubuntu] Packages being kept back

# apt-get upgrade
Reading package lists... Done
Building dependency tree... Done
The following packages have been kept back:
openssh-client openssh-server
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
# apt-get install openssh-client openssh-server
Reading package lists... Done
Building dependency tree... Done
The following extra packages will be installed:
openssh-blacklist
Suggested packages:
rssh
The following NEW packages will be installed:
openssh-blacklist
The following packages will be upgraded:
openssh-client openssh-server
2 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 2909kB of archives.
After unpacking 4280kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://us.archive.ubuntu.com dapper-updates/main openssh-blacklist 0.1-1ubuntu0.6.06.1 [2125kB]
Get:2 http://us.archive.ubuntu.com dapper-updates/main openssh-server 1:4.2p1-7ubuntu3.4 [207kB]
Get:3 http://us.archive.ubuntu.com dapper-updates/main openssh-client 1:4.2p1-7ubuntu3.4 [577kB]
Fetched 2909kB in 45s (63.6kB/s)
Preconfiguring packages ...
Selecting previously deselected package openssh-blacklist.
(Reading database ... 93922 files and directories currently installed.)
Unpacking openssh-blacklist (from .../openssh-blacklist_0.1-1ubuntu0.6.06.1_all.deb) ...
Preparing to replace openssh-server 1:4.2p1-7ubuntu3.3 (using .../openssh-server_1%3a4.2p1-7ubuntu3.4_i386.deb) ...
Unpacking replacement openssh-server ...
Preparing to replace openssh-client 1:4.2p1-7ubuntu3.3 (using .../openssh-client_1%3a4.2p1-7ubuntu3.4_i386.deb) ...
Unpacking replacement openssh-client ...
Setting up openssh-blacklist (0.1-1ubuntu0.6.06.1) ...
Setting up openssh-client (4.2p1-7ubuntu3.4) ...

Setting up openssh-server (4.2p1-7ubuntu3.4) ...
* Restarting OpenBSD Secure Shell server... [ ok ]

#

2008-06-06

[Ubuntu 6.06] Disable IPv6

系统启动到 IPv6 over IPv4 tunneling driver 时候 hang 住了

2008-06-05

Hex Editors

  • apt-cache search -n hex
  • apt-get install hexedit
  • apt-get install hexer
  • apt-get install hexcurse
  • apt-get install ncurses-hexedit
--
hex edit editor

2008-05-17

Ubuntu 8.04

前天收到了从 Netherland 寄来的 Ubuntu 8.04 的 CD, 里面已经 officially 包含了 Wubi 安装程序, 在 Windows XP 上安装了一下, 很顺畅, 没遇到什么麻烦, 只是在安装过程中有个进度条竟然到了 128%, 应该是个小 bug. 启动之后使用正常, 只发现一点儿小问题: 音量控制不起作用.

2008-03-24

Wubi

试用了一下 Wubi, 装了 ubuntu-7.04 在 windows-xp 上, 整体感觉还是很流畅的, 不错.

2008-02-27

Wubi - Install Ubuntu Inside Windows

Wubi is an unofficial Ubuntu installer for Windows users that will bring you into the Linux world with a single click. Wubi allows you to install and uninstall Ubuntu as any other application. If you heard about Linux and Ubuntu, if you wanted to try them but you were afraid, this is for you.

2008-02-19

[Ubuntu] Desktop vs. Server

Desktop 版跟 Server 版使用不同的 kernel:

desktop: linux-image (linux-image-2.6.15-23)
server: linux-image-server (linux-image-2.6.15-23-server)

desktop # uname -a
Linux ubuntu606 2.6.15-51-386 #1 PREEMPT Tue Feb 12 16:52:52 UTC 2008 i686 GNU/Linux
server # uname -a
Linux dapper-server 2.6.15-51-server #1 SMP Thu Dec 6 21:37:18 UTC 2007 i686 GNU/Linux

desktop 跟 server 的 /etc/lsb-release 也是相同的:
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=6.06
DISTRIB_CODENAME=dapper
DISTRIB_DESCRIPTION="Ubuntu 6.06.2 LTS"

Compiling Expect 5.43 on Ubuntu 6.06

  • $ apt-get install tcl8.4-dev
  • $ wget http://expect.nist.gov/expect.tar.gz
  • $ tar -xzf ...
  • $ ./configure --prefix=... --with-tcl=/usr/lib/tcl8.4 --with-tclinclude=/usr/include/tcl8.4/tcl-private
  • $ make
  • $ make install

2008-02-17

Apt-file does not work for Dapper

近日发现 apt-file 不好用了, 不解. 看了一下 apt-file 的 man page, 它要用到 server 上的一个叫 Contents-i386.gz 的文件, 所有的信息应该都在这个文件里面, 然而 server 上的这个文件大小只有 677 个 byte. 到 server 的 Edgy 的目录里面看了一下, 这个文件的大小有 11M 呢, 不晓得 Dapper 里面的这个文件为什么这么小了. 心生一计, 来个偷梁换柱, 把 Edgy 里面的文件 download 下来改名成 Dapper 的就好了!

2008-02-15

Locale variables

Variable What it's for
LANG The basic language setting used by applications on the system, unless overridden by one of the other locale environment variables
LC_CTYPE The character set used to display and input text
LC_NUMERIC How non-monetary numeric values are formatted on screen
LC_TIME How date and time values are formatted
LC_COLLATE How to sort various information items (e.g. defines the order of the alphabet so items can be ordered alphabetically by the sort command)
LC_MONETARY How monetary numeric values are formatted
LC_MESSAGES Which language is to display messages to the end user
LC_PAPER Definitions of paper formats and standards
LC_NAME How names are formatted
LC_ADDRESS How to display address information
LC_TELEPHONE How telephone numbers are structured
LC_MEASUREMENT What units of measurement are used
LC_IDENTIFICATION
LC_ALL This variable serves as a powerful override over all the other locale environment variables. When its value is set, applications use that value to determine which locale settings to use regardless of the values of the other variables

2008-02-14

Searching Ubuntu Packages

http://packages.ubuntu.com/

[Ubuntu] Components

Components

The Ubuntu software repository is divided into four components, main, restricted, universe and multiverse on the basis of our ability to support that software, and whether or not it meets the goals laid out in our Free Software Philosophy.

The standard Ubuntu installation is a subset of software available from the main and restricted components. You can install additional software using installation software such as Synaptic Package Manager or Aptitude. Other components are added by editing the /etc/apt/sources.list file. See "man sources.list" for more information on editing the sources.list file.

"main" component

The main distribution component contains applications that are free software, can freely be redistributed and are fully supported by the Ubuntu team. This includes the most popular and most reliable open source applications available, much of which is installed by default when you install Ubuntu.

Software in main includes a hand-selected list of applications that the Ubuntu developers, community, and users feel are important and that the Ubuntu security and distribution team are willing to support. When you install software from the main component you are assured that the software will come with security updates and technical support.

We believe that the software in main includes everything most people will need for a fully functional desktop or internet server running only open source software.

The licences for software applications in main must be free, but main may also may contain binary firmware and selected fonts that cannot be modified without permission from their authors. In all cases redistribution is unencumbered.

"restricted" component

The restricted component is reserved for software that is very commonly used, and which is supported by the Ubuntu team even though it is not available under a completely free licence. Please note that it may not be possible to provide complete support for this software since we are unable to fix the software ourselves, but can only forward problem reports to the actual authors.

Some software from restricted will be installed on Ubuntu CDs but is clearly separated to ensure that it is easy to remove. We include this software because it is essential in order for Ubuntu to run on certain machines - typical examples are the binary drivers that some video card vendors publish, which are the only way for Ubuntu to run on those machines. By default, we will only use open source software unless there is simply no other way to install Ubuntu. The Ubuntu team works with such vendors to accelerate the open-sourcing of their software to ensure that as much software as possible is available under a Free licence.

"universe" component

The universe component is a snapshot of the free, open source, and Linux world. In universe you can find almost every piece of open source software, and software available under a variety of less open licences, all built automatically from a variety of public sources. All of this software is compiled against the libraries and using the tools that form part of main, so it should install and work well with the software in main, but it comes with no guarantee of security fixes and support. The universe component includes thousands of pieces of software. Through universe, users are able to have the diversity and flexibility offered by the vast open source world on top of a stable Ubuntu core.

Canonical does not provide a guarantee of regular security updates for software found in universe but will provide these where they are made available by the community. Users should understand the risk inherent in using packages from the universe component.

Popular or well supported pieces of software will move from universe into main if they are backed by maintainers willing to meet the standards set for main by the Ubuntu team.

"multiverse" component

The "multiverse" component contains software that is "not free", which means the licensing requirements of this software do not meet the Ubuntu "main" Component Licence Policy.

The onus is on you to verify your rights to use this software and comply with the licensing terms of the copyright holder.

This software is not supported and usually cannot be fixed or updated. Use it at your own risk.

2008-01-14

[Ubuntu 6.06] chown changes file permissions?

# ls -l foo.sh
-rwxr-xr-x 1 root root 23 2007-08-16 14:30 foo.sh
# chmod u+s foo.sh
# ls -l foo.sh
-rwsr-xr-x 1 root root 23 2007-08-16 14:30 foo.sh
# chown root:root foo.sh
# ls -l foo.sh
-rwxr-xr-x 1 root root 23 2007-08-16 14:30 foo.sh
# uname -a
Linux ubuntu 2.6.15-27-686 #1 SMP PREEMPT Sat Sep 16 02:13:27 UTC 2006 i686 GNU/Linux
#

2007-07-26

Perl Misc

近两年没怎么用 perl, 忘得差不多了:

2007-07-11

Bash on Debian/Ubuntu does not support using the /dev/tcp and /dev/udp files

$ cat < /dev/tcp/localhost/daytime
bash: /dev/tcp/localhost/daytime: No such file or directory
$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=6.06
DISTRIB_CODENAME=dapper
DISTRIB_DESCRIPTION="Ubuntu 6.06.1 LTS"
$