Quantcast
Channel: web-mix labs » Linux
Browsing latest articles
Browse All 10 View Live

findでディレクトリだけパーミッションを変更する

ディレクトリだけパーミッションを変更しないといけないような場合、find と組み合わせて実行すれば良いようです。 カレントディレクトリとその配下のディレクトリのパーミッションを変更する場合は以下の通り。 find . -type d -exec chmod 755 {} \; chmod 755 の部分を他のコマンドにすれば、いろいろ出来ますね。

View Article



CentOSでLZHを解凍する

CentOS上でLZH形式の圧縮ファイルを解凍するには、lhaコマンドを使う。 yumで簡単インストール♪ yum --enablerepo=rpmforge install lha 解凍はこんな感じ。 lha x file.lzh

View Article

Debianで時刻あわせ

Debianがいつも9時間ずれてるのを直すことに。 まずは時刻を確認。 debian:~# date 2010年 2月 1日 月曜日 02:06:45 EST やっぱりずれてる。(今は16時) ntpdateで時刻同期してみる。 debian:~# ntpdate clock.nc.fukuoka-u.ac.jp 1 Feb 02:09:47 ntpdate[3576]: step time...

View Article

Debianのバージョンを確認する

Debian の場合、OSのバージョンはファイルに記述してあるだけなので、 lessなどで確認する事が出来るようです。 # less /etc/debian_version 4.0 4.0ということはetchですね~

View Article

Debianにaptitudeをインストール

apt-getの便利バージョンのaptitudeを入れてみます。 aptitudeはapt-getのinstallとupdateを一気にやってくれて、依存関係の解消も少し向上しているそうですね。 インストールはapt-getで出来ました。 # apt-get install aptitude パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています... 完了...

View Article


DebianでlocateのDBを更新する

ファイルを探すときに便利なlocateですが、通常は定期的にDBが更新され、検索したファイルが表示されます。 こんな感じ。 # locate php.ini /etc/php5/apache2/php.ini /etc/php5/apache2/php.ini.ucf-dist /etc/php5/cli/php.ini...

View Article

CentOSのバージョンを確認する

よく忘れるのでメモ。 [root@localhost ssh]# cat /etc/redhat-release CentOS release 5.4 (Final) ちなみにDebianの場合はこちら

View Article

CentOSを日本語化する

CentOS5.4を日本語化します。 # vi /etc/sysconfig/i18n #LANG="C" LANG="ja_JP.UTF-8" SYSFONT="latarcyrheb-sun16" あとはログインしなおせば日本語化されているはずです。

View Article


yumでアーキテクチャを指定してインストール

テキストから図を自動生成する事が出来る「graphviz」をインストールしようとした時に、 思わぬエラーに遭遇しました。 # yum install graphviz Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: ftp.nara.wide.ad.jp * epel:...

View Article


「Device eth0 has different MAC address than expected, ignoring.」のエラーを解消

Virtual PCのCentOSにSSH接続しようとしたら繋がらない。 そこでネットワークを再起動してみると・・ # service network restart : Bringing up loopback interface: [ OK ] Bringing up interface eth0: Device eth0 has different MAC address than...

View Article
Browsing latest articles
Browse All 10 View Live




Latest Images