Вход/Регистрация
Linux
вернуться

Стахнов Алексей Александрович

Шрифт:
...

Замечание

Команда указывает компилировать утилиту smbmount, которая служит для монтирования SMB-ресурсов в файловую структуру Linux, включает поддержку Microsoft DFS и указывает устанавливаться после компиляции в каталог /opt/samba. Конечно, есть еще много параметров, которые можно назначить. Подробную информацию о них следует смотреть в документации к пакету Samba или вызывать командой configure –help.

4. Следующим действием необходимо набрать в командной строке make и нажать <Enter>. Этой командой запускается процесс компиляции программного пакета.

5. Если в ходе работы программы make не появились сообщения об ошибках, то надо выполнить команду make install. Эта команда установит пакет Samba в ее родной каталог (если действовать в точности по инструкции, то файлы попадут в каталог /opt/samba).

Теперь на очереди конфигурирование сервера Samba.

Файл конфигурации smb.conf

Самое трудное, с чем можно столкнуться при настройке сервера Samba, – это создание (или редактирование) файла конфигурации. Все файлы конфигурации Samba находятся в каталоге /etc/samba. Вот список файлов, которые обычно содержатся в этом каталоге:

• lmhosts – содержит список хостов и соответствующих им адресов;

• smbpasswd – содержит пароли пользователей сервера Samba;

• smbusers – файл, предназначенный для хранения списка пользователей, которым разрешен доступ к ресурсам Samba;

• smb.conf – главный конфигурационный файл сервера.

Примеры конфигурационных файлов, поставляемых с пакетом, находятся в каталоге /examples. В большинстве случаев их можно использовать в качестве базы.

Далее приведен файл smb.conf сервера Samba, который успешно функционирует на одном из серверов.

Листинг 24.1. Пример файла smb.conf

# This is the main Samba configuration file. You should read the

# smb.conf(5) manual page in order to understand the options listed

# here. Samba has a huge number of configurable options (perhaps too

# many!) most of which are not shown in this example

# Any line which starts with a; (semi-colon) or a # (hash)

# is a comment and is ignored. In this example we will use a #

# for commentry and a; for parts of the config file that you

# may wish to enable

# NOTE: Whenever you modify this file you should run the command "testparm"

# to check that you have not many any basic syntactic errors.

#

#======================= Global Settings ==============================

[global]

# workgroup = NT-Domain-Name or Workgroup-Name workgroup = Kontora

# server string is the equivalent of the NT Description field server string = Kontora Samba Server

# This option is important for security. It allows you to restrict

# connections to machines which are on your local network. The

# following example restricts access to two С class networks and

# the «loopback» interface. For more examples of the syntax see

# the smb.conf man page

hosts allow = 192.168.10. 193.166.17.

# if you want to automatically load your printer list rather

# than setting them up individually then you\'ll need this

# printcap name = /etc/printcap

# load printers = yes

# It should not be necessary to spell out the print system type unless

# yours is non-standard. Currently supported print systems include:

# bsd, sysv, pip, lprng, aix, hpux, qnx

printing = lprng

# Uncomment this if you want a guest account, you must add this to /etc/passwd

# otherwise the user «nobody» is used

; guest account = pcguest

# this tells Samba to use a separate log file for each machine

# that connects

log file = /var/log/samba/%m.log

# Put a capping on the size of the log files (in Kb). max log size = 0

# Security mode. Most people will want user level security. See

# security_level.txt for details.

security = user

# Use password server option only with security = server or

# security = domain

; password server = <NT-Server-Name>

# Password Level allows matching of _n_ characters of the password for

# all combinations of upper and lower case.

; password level = 8

; username level = 8

# You may wish to use password encryption. Please read

# ENCRYPTION.txt, Win95.txt and WinNT.txt in the Samba documentation.

# Do not enable this option unless you have read those documents

encrypt passwords = yes

smb passwd file = /etc/samba/smbpasswd

  • Читать дальше
  • 1
  • ...
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • ...

Ебукер (ebooker) – онлайн-библиотека на русском языке. Книги доступны онлайн, без утомительной регистрации. Огромный выбор и удобный дизайн, позволяющий читать без проблем. Добавляйте сайт в закладки! Все произведения загружаются пользователями: если считаете, что ваши авторские права нарушены – используйте форму обратной связи.

Полезные ссылки

  • Моя полка

Контакты

  • chitat.ebooker@gmail.com

Подпишитесь на рассылку: