Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Linux Timesaving Techniques For Dummies.pdf
Скачиваний:
59
Добавлен:
15.03.2015
Размер:
15.98 Mб
Скачать

Tweaking Your Configuration Files with Webmin

365

pretty fair configuration file to get you started. The installation and initial setup is super-fast!

To install Sendmail, follow these steps:

1. Open a terminal window and give yourself superuser privileges with the su - command.

2. Insert and mount your distribution media. Use the cd command to move into the directory containing the sendmail RPM packages.

3. Install sendmail with the following command:

# rpm -Uhv sendmail-version.i386.rpm

4.Install the sendmail configuration file with the following command:

#rpm -Uhv sendmail-cf-version.i386.rpm

Be sure to choose the version that you see on your distribution media.

That’s it — Sendmail is installed.

To start Sendmail on a Fedora computer, use the following command:

# service sendmail start

If you’re a SuSE user, type in this command:

# rcsendmail start

Or, if you’re running Mandrake Linux, use this command:

# /etc/init.d/sendmail start

The configuration can still use some tweaking, but Webmin can help with that, as described in the next section.

Tweaking Your Configuration Files with Webmin

In Technique 17, we walk you through an installation

installed it already, check out Technique 17 for instructions.

Webmin is a browser-based administration tool that provides an easy-to-use interface for servers, security issues, and other administrative tasks. It’s definitely worth getting to know.

After installing Webmin, follow these steps to access the Sendmail Configuration menu:

1. Open your favorite Web browser and surf to

localhost:10000/

Webmin opens to the login screen.

2. Enter your user name and password and click the Login button.

The Webmin main menu appears, as shown in Figure 48-1.

Figure 48-1: The Webmin main menu.

3.Click the Servers button at the top of the page.

The Servers page opens.

4.Click the Sendmail Configuration button, near the bottom of the page.

The Sendmail Configuration menu opens, as shown in Figure 48-2.

of the top-notch tool, Webmin. If you haven’t

366 Technique 48: Using Webmin to Simplify Sendmail Configuration

• Figure 48-2: The Sendmail Configuration menu.

One quick glance tells you that Sendmail is a complex but powerful program. Fortunately, most of the default configuration options are okay, and the customizations are simple with Webmin. The following sections detail how to customize settings from the Sendmail Configuration menu.

• Figure 48-3: The Local Domains list.

2. Add your domain names to the list and then click the Save button.

You can send and receive e-mails only from registered names that point to your current e-mail address.

Serving up mail for multiple domains

You can use Sendmail to retrieve e-mail from multiple DNS servers if you have multiple registered names that point to the same server address. To serve up e-mail for multiple domains, you need two things:

Multiple DNS records that list your server and its current address

Multiple listings in the Local Domains list for your Sendmail configuration file

From the Sendmail Configuration menu, follow these steps to add the listings to the Local Domains list:

1. Click the Local Domains (Cw) button near the top of the Sendmail Configuration menu.

The Local Domains page opens, as shown in Figure 48-3.

Relaying e-mail

If you need to allow remote employees to send e-mail through your local network, take advantage of the Spam Control (Access) feature of Sendmail. With message relaying, the end user sees your employee’s e-mail as coming from your local network even if

the employee is accessing your mail server from a distance.

This feature is really intended to keep nasty people out of your system. Spammers with ill intentions often hack systems to route e-mail through unsuspecting Sendmail hosts. Be cautious about setting up relays for friends or employees with loose security habits.

From the Sendmail Configuration menu (refer to Figure 48-2), follow these steps to set up message relaying:

Tweaking Your Configuration Files with Webmin

367

1. Click the Spam Control (Access) button to open the Spam Control menu, shown in Figure 48-4.

Figure 48-4: The Spam Control menu.

2.Choose Domain from the Mail Source dropdown list, and to the right of this list, enter the domain address of your remote employee. Then select the Allow Relaying radio button and click Create.

The new relay is added to the list of sources.

3.Click the Return to sendmail configuration link (at the bottom of the page) to go back to the Sendmail Configuration menu.

4.Click the Stop Sendmail button at the bottom of the page. When the button name changes to Start Sendmail, click it again to make the changes to your configuration file take effect.

Using aliases to simplify mail handling

You can redirect e-mail on your system with Sendmail’s Alias feature. If you have an incoming address that you want distributed to multiple individuals, follow these steps:

1. Click the Mail Aliases (Aliases) button on the

Sendmail Configuration menu.

The Mail Aliases menu appears.

You may want to use the Alias feature to distribute sales inquiries to your entire sales force, technical inquiries to an entire support department, or a humorous mailing to everyone.

2. Enter the address in the Alias Address field.

The address should not include a domain or an extension.

3. If you want the alias to take effect immediately, check the Enabled radio box.

4. In the Alias To drop-down list box, select

Addresses in File, and to the right of the list box, enter the file name, as shown in Figure 48-5.

5. Click Create to add the new alias.

• Figure 48-5: Creating a mail alias.

The new alias is created and added to the list. Now, when an e-mail is sent to the address in the alias, Sendmail redistributes it to all the e-mail addresses in the file.

You can create e-mail address files quickly with your favorite text editor. Enter one address per line and save the file somewhere safe but memorable.

368 Technique 48: Using Webmin to Simplify Sendmail Configuration

Any server is a potential security risk. With an e-mail server, you run multiple risks from hackers that want to exploit the free use of your server (and address) to create potential system vulnerabilities. A UML jail might be a good place to keep a mail server — see Technique 58 for details.

Part IX

Backing Up Means

Never Having to

Say You’re Sorry

49

Getting Ready

 

 

to Back Up

Technique

Your Data

 

Save Time By

Choosing the right backup media

Choosing the right backup scheme

Choosing the right archive type

Archiving important data is vital — no question about that. Setting up an archiving scheme that’s easy to use (and easy to restore from) is important. Unless you make the process quick and easy,

and enforce your routine with discipline, you’ll find it too easy to slack off and forget to back up an irreplaceable piece of work. We know — we’ve had to learn the hard way.

For the small system or single computer, the consequences of data loss might not affect other people, but losing your own work is still losing time. Having a dependable backup system is just as important to single users as it is to administrators of large networks.

Choosing the right backup media can make the difference between painful and tedious backup jobs, and backup jobs that are simple and unobtrusive. If you’re the administrator of a large network, it’s especially important that you choose your media well — other people’s work is in your hands. Choosing dependable media (preferably stored off-site) helps ensure a safe recovery if you do need to restore from backup.

In addition to choosing the type of media you’ll be using to back up your system, you need to consider whether incremental, differential, or full backups are best for your system. Differential backups are great if resources (such as money for media) are limited and you don’t need to restore often. Incremental backups are quicker to restore, but they consume more media than a differential backup. If you need to restore from backup often but have the resources to do full backups, automating full backups saves restoration time in the long run.

Selecting a good archive tool is important, too, and you have a large number of options. Commercial backup tools are typically easy to use and well suited for both commercial and home use. A ton of free archive tools are also available, a few of which are already loaded on your computer.

In this technique, we give you some food for thought about choosing a backup scheme for your system. Whether your system is large or small, if you’ve got important information on it, backing up is important. We give

Соседние файлы в предмете Операционные системы