変更履歴
For more detail see
11th September 2005
Revised by [[User:Manager|Chris Lale]]
7th January 2006
Revised by [[User:Manager|Chris Lale]]
Modified for NewbieDOC. Changed title
from 'What you might like to know before
you install Debian GNU/Linux'.
最新版
要約
この記事は、Debian GNU/Linux の基本的な機能の一部を説明します。これらは、Debian をあなたのコンピュータにインストールする前に知りたいと思うことです。
Debian とは
Debian GNU/Linux は、フリーなオペレーションシステムです。オペレーションシステムのエンジンは、カーネルと呼ばれます。Debian は、Linux カーネルを利用します。カーネルを使わせるオペレーションシステムの残りの部分は、数多くのツールから構成されます。Debian では、これらのツールは GNU プロジェクトにより供給されています。
Windows の置き換えとして Debian をインストールできますし、デュアルブートシステムの一部としてもインストールできます。
Linux ファイルシステム
Windows は、ドライブそれぞれに対してディレクトリツリーが存在します。各ツリーの名前は、ドライブレターで始まります。
Linux には、ファイルシステムと呼ばれる一つのツリーしか存在しません。ツリーは、ルートディレクトリを示す記号 '/' で始まります。(root と呼ばれる特別なユーザが存在します。root ユーザのホームディレクトリは、'/root' です。
'/' と '/root' を取り違えないでください。)
ルートディレクトリには、複数のサブディレクトリが存在します。
- bin - 基本的なコマンドバイナリが含まれる
- boot - ブートローダ用のスタティックファイルが含まれる
- dev - デバイスファイル
- etc - ホストに特有のシステム設定ファイルが含まれる
- home- ユーザのホームディレクトリ
- lib- 基本的な共有ライブラリとカーネルモジュールが含まれる
- media - リムーバブルメディアへのマウントポイント
- mnt- ファイルシステムを一時的にマウントするためのマウントポイント
- opt - アドオンアプリケーションソフトウェアパッケージが含まれる
- root - root ユーザ用ホームディレクトリ
- sbin - 基本的なシステムバイナリが含まれる
- tmp - 一時的ファイルが含まれる
- usr - (ユーザがインストールしたアプリケーションのための) 二次階層
- var - 可変領域
Linux では、ユーザはどの物理的なドライブに特定のデータが含まれているのかを気にする必要はありません。
ここが、どのドライブ (C: や D: など) を使えば良いのかを知る必要がある Windows と異なる点です。
Linux では、その代わりにディレクトリツリーの特定のマウントポイントにドライブをマウントします。例えば、Windows にて一代目の CD ドライブは D: または E: や別の他のドライブレターだったりするかもしれませんし、ドライブを追加したり削除したりすると、ドライブレターが変わってしまうかもしれません。
Linux では、一代目の CD ドライブのマウントポイントは
/media/cdrom0
です。ドライブを追加削除してもマウントポイントは変わりません。ただし、
/cdrom
のようなファイルシステムへの便利なショートカットを追加できます。
Windows でアプリケーションをインストールする場合、実行ファイルや関連ファイルは、通常
C:\Program Files
にインストールされます。Linux では、次に示すように、ファイルの種類に応じてインストール先が異なります。
- アプリケーションの実行ファイル (バイナリ) は、/usr/bin へ。
- マニュアルは、 /usr/share/man へ。
- 他のドキュメントは、/usr/share/doc</code> へ。
Linux には、レジストリが存在しません。設定データは、通常テキストファイル形式で /etc/ にインストールされます。
ディスクデバイスとパーティション
Windows では、プライマリマスタ IDE ドライブにある有効な第一ドライブは C: と呼ばれます。他のパーティション (および CDROM ドライブ) は、D:、E: などと呼ばれます。
Windows 98 以前では、ドライブレターの割り当ては、自動で行われ、固定されていました。Windows NT 以降から、ドライブレターの一部を再割り当て可能になりました。
Linux では、"全てがファイルだ" と良くいわれます。ドライブの場合には、プライマリ IDE マスタードライブの全体は、
/dev/hda
デバイスであり、プライマリスレーブは、
/dev/hdb
セカンダリマスターは、
/dev/hdc
そしてセカンダリスレーブは
/dev/hdd
です。
一台目の SCSI ハードディスクは、
/dev/sda
二台目は
/dev/sdb
などになります。SCSI CD または SCSI DVD ドライブは、
/dev/scd0
などです。
(フラットケーブルで接続された) パラレル ATA ドライブは、IDE ATA ドライブ (/dev/hda) として扱われます。
(フラットケーブルで接続されない) シリアル ATA ドライブは、SCSI ドライブ (/dev/sda、/dev/sdb など) として
扱われます。
ハードディスク上に 4 個までのプライマリパーティションを作成できます。それらの一つは、63 個までの他の論理パーティション
を含む拡張パーティションにできます。
Windows のユーザは、たった一つのプライマリパーティションと、論理パーティションを含む一つの拡張パーティションしか使えません。
Linux は、全てのパーティションを使えますが、Debian で 1 ディスク当たり 20 個以上のパーティションを使う場合には、手動で設定する必要があります。
/dev/hda が、ふたつのプライマリパーティションにフォーマットされた場合、パーティションはそれぞれ /dev/hda1 と /dev/hda2 となります。
典型的なデュアルブートシステム (Windows/Linux )では、プライマリパーティション 1 は Windows のドライブ C になりますので、Linux からは /dev/hda1 としてアクセスできます。
パーティション 2 (/dev/hda2) は、Windows の拡張パーティションですが、Windows からは直接アクセスする必要はありません。
パーティション 3 とパーティション 4 は使われませんし、パーティション 5 以降は、拡張パーティション内のパーティションです。パーティション 5 は、ドライブ D: 又は /dev/hda5 となります。
CD ドライブ又は DVD ドライブはパーティション分けできません。典型的な CD ドライブは、/dev/hdc (IDE 接続時) 又は
/dev/scd0 (SCSI 接続時) となります。
Windows で二つのフロッピードライブ A: と B: がある場合、
Linux では、フロッピードライブは /dev/fd0 と /dev/fd1 になります。
デバイスのマウントとアンマウント
Linux では、全てはファイルです - ハードディスクなどのデバイスを含みます。ディスクを使うためには、デバイスをファイルシステム中のマウントポイントにマウントする必要があります。
そうすると、マウントポイントからディスクにアクセスできます。例えば、システムのバックアップを取るために別のハードディスクを使いたいとします。EXT3 フォーマットされた別のディスク /dev/hdb1 を追加姿態場合には、マウントポイントとして新しいディレクトリ /mnt/backup を作成できます。
そして、'mount'コマンドにより、次のようにパーティションをマウントできます。
$ mount -t ext3 /dev/hdb1 /mnt/backup
そして、'umount' コマンドを使って次のようにアンマウントします。
$ umount /mnt/backup
又は
$ umount /dev/hdb1
/etc/fstab という設定ファイルには、ブート時に自動でマウントされるデバイスの詳細が含まれます。
automounter をインストールすれば、リムーバブルデバイスを自動でマウントするように設定できます。
X-window 用のデスクトップ環境 Gnome には、自動マウント機能が標準で含まれています。マウントされたメディアは、メディア上の全てのファイルに関わるプロセスが全て終了するまで、アンマウントやイジェクトができません。
Gnome で CD をアンマウントするには、CD アイコンを右クリックしてイジェクトを選択するだけです。
ファイルシステムフォーマット
Linux で最も用いられているファイルシステムフォーマットは、EXT2 (the Second Extended file system format) です。最近のディストリビューションは、EXT3 ファイルシステムを使っており、これは、EXT2 にジャーナリングシステムを追加したものです。ジャーナルは、データの損失などを引き起こしかねないファイルシステムデータの破損を保護するものです。
障害に対して強固になるだけでなく、EXT2/3 パーティションは効率的かつデフラグメンテーションが必要ありません。
ファイルシステムチェッカ 'fsck' によりデータ破損チェックおよび修復が可能です。これは、Windows における scandisk
に似たものです。
Linux におけるマルウェア
There has not been a real Linux virus epidemic in the wild. This is because a virus (or any other program) can only carry out actions that the user running the virus is allowed to do. Normal users do not have enough privileges to cause damage to the system. Only user root can do that. You would have to run an untrusted binary as root to run any risk. Desktop users routinely do not log in asroot, and only switch user to root to run specific, trusted software. You have to deliberately try to circumvent this protection and know the root password to be at risk.
Worms exploit known security holes. Generally, there are very few new or unknown holes. Defeating worms and trojans is as easy as keeping software up to date.
There are Anti-Virus scanners available for Linux (but generally speaking no Linux viruses). However, they will pick up Windows viruses and stop you spreading them to Windows users.
== Linux security ==
The most important practice is never to login as user root (the superuser). Only user root has access to everything - that is why you must be root during the installation process. Always login as a normal user (low privileged user). If you need root privileges for an application, switch user to root as follows:
certain X applications, eg the software installer Synaptic, prompt for user root's password,
for other X applications, run<code>gksu</code> followed by space followed by the command that launches the application,
for console commands, switch user with the<code>su</code> command to obtain user root's prompt (<code>#</code>) then issue the command. When you have finished, enter <code>exit</code> or press ctrl-D to resume as the normal user (<code>$</code> prompt).
Debian is installed with security features enabled by default. You can disable features that you do not need, but you are unlikely to do this unless you know what you are doing. This approach means that you are unlikely to make yourself vulnerable through ignorance or accident.
For a computer connected to the internet, keeping the system constantly up to date means that security holes are plugged almost as soon as they are discovered. You need this line (uncommented ie without a preceding <code>#</code>) in your <code>/etc/apt/sources.list</code> file:
<nowiki>deb http://security.debian.org/ sarge/updates main contrib non-free</nowiki>
== Linux bugs ==
Anyone finding a bug in Debian can report it using the bug tracking system. Most of the bugs are sorted out before the software moves into the stable distribution ( ie in the testing or unstable distributions). See
http://www.debian.org/Bugs/.
== Running Windows applications ==
There are commercial emulators such as Vmware.
== Installing software ==
The traditional way of installing Linux software is by compiling the binary (executable file) on your own computer from source code. This is actually quite easy and is one of the reasons why viruses are not a problem in Linux - they normally hide in pre-compiled binaries but are obvious foreigners in source code. The drawback for the novice user is that Linux is modular and an application may depend on one or more other applications, which in turn may depend on other applications, etc. So you may find that compilation fails because you have not installed all the necessary depenedencies.
This is solved by Debian's packaging system Apt (Red Hat Linux has an alternative packaging system called Rpm). In Debian, the application is pre-compiled for your computer's architechture and packaged together with associated files, configuration data, etc in a single <code>.deb</code> file. The package also knows which other packages (dependencies) are needed and installs them too automatically. You can install packages with Synaptic (X) or <code>aptitude</code> or <code>apt-get</code> (commandline).
== Help and support ==
Most problems can be solved by reading the documentation:
man page (eg <code>man man</code> diplays the manual for the man command)
info page (the <code>info</code> command)
Dwww (man and info pages with a web interface)
files in <code>/usr/share/doc/app-name</code>
HOWTOs (eg the Linux Documentation Project (http://tldp.org/)
internet home page for the application
internet wikis
internet forums
internet mailing list archives (try Google with 'site:lists.debian.org search-term-1 search-term-2 ...')
NewbieDOC wiki
== Appendix A: Licence ==
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no
Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license can be found at
http://www.fsf.org/copyleft/fdl.html.
-
-
最終更新:2007年04月23日 00:57