openSUSE 12.
Start-Up Copyright © 2006– 2011 Novell, Inc. and contributors. All rights reserved. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or (at your option) version 1.3; with the Invariant Section being this copyright notice and license. A copy of the license version 1.2 is included in the section entitled “GNU Free Documentation License”. For Novell trademarks, see the Novell Trademark and Service Mark list http://www.
Contents About This Guide ix Part I Installation and Basics 1 1 Installation Quick Start 3 1.1 3 2 3 Welcome to openSUSE . . . . . . . . . . . . . . . . . . . KDE Quick Start 11 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 2.10 2.11 2.12 2.13 2.14 2.15 2.16 2.17 2.18 2.19 11 12 14 15 20 21 22 26 28 30 31 32 32 34 35 36 37 38 39 Getting Started . . . . . . . . . . . . . . . . . . . . . . Starting Programs . . . . . . . . . . . . . . . . . . . . . Handling Media . . . . . . . . . . . . . . . . . . . .
3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 3.15 3.16 3.17 3.18 3.19 4 Starting Programs . . . . . . . . . . . . . . . . . . . . . Handling Media . . . . . . . . . . . . . . . . . . . . . . Customizing Your Desktop . . . . . . . . . . . . . . . . . Applying Desktop Effects . . . . . . . . . . . . . . . . . . Using Virtual Desktops . . . . . . . . . . . . . . . . . . . Managing Files and Folders . . . . . . . . . . . . . . . . . Browsing the Internet with Firefox . . . . . . . . . . . . . .
7 Installing Packages From the Internet 7.1 7.2 8 Installing Add-On Products 8.1 8.2 9 1-Click Install . . . . . . . . . . . . . . . . . . . . . . YaST Package Search . . . . . . . . . . . . . . . . . . . Add-Ons . . . . . . . . . . . . . . . . . . . . . . . . . Binary Drivers . . . . . . . . . . . . . . . . . . . . . . Managing Software with Command Line Tools 9.1 9.2 Using Zypper . . . . . . . . . . . . . . . . . . . . . . RPM—the Package Manager . . . . . . . . . . . . . . . .
1 4 Printer Operation 14.1 14.2 14.3 14.4 14.5 14.6 14.7 14.8 161 The Workflow of the Printing System . . . . . . . . . . . . Methods and Protocols for Connecting Printers . . . . . . . . Installing the Software . . . . . . . . . . . . . . . . . . Setting Up a Printer . . . . . . . . . . . . . . . . . . . . Network Printers . . . . . . . . . . . . . . . . . . . . . Printing from the Command Line . . . . . . . . . . . . . . Special Features in openSUSE . . . . . . . . . . . . . . . Troubleshooting . . . .
18.5 18.6 18.7 18.8 A Using Variables in Bash . . . . . . . Grouping And Combining Commands . Working with Common Flow Constructs For More Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Help and Troubleshooting A.1 A.2 A.3 A.4 Help and Documentation . . . . . . Common Problems and Their Solutions Legal Notice . . . . . . . . . . . . GNU Free Documentation License . . 230 232 233 234 235 . . . . . . . . . . . . . . . .
About This Guide This manual will see you through your initial contact with openSUSE®. Check out the various parts of this manual to learn how to install, use and enjoy your system. Installation and Setup Guides you through the installation process and the basic configuration of your system. Introduces YaST, the central tool for installation and configuration of your system. Learn how to set up or modify key components of your system and how to connect to the internet.
Reference (↑Reference) Gives you a general understanding of openSUSE and covers advanced system administration tasks. It is intended mainly for system administrators and home users with basic system administration knowledge. It provides detailed information about advanced deployment scenarios, administration of your system, the interaction of key system components and the set-up of various network and file services openSUSE offers.
at the bottom of each page in the online documentation or go to http://www .novell.com/documentation/feedback.html and enter your comments there.
Your SUSE Team xii Start-Up
Part I.
1 Installation Quick Start Use the following procedures to install a new version of openSUSE® 12.1. This document gives a quick overview on how to run through a default installation of openSUSE. 1.1 Welcome to openSUSE For more detailed installation instructions and deployment strategies, see the openSUSE documentation at http://www.novell.com/documentation/opensuse114/. 1.1.1 System Requirements • Pentium* III 500 MHz or higher processor (Pentium 4 2.
2 Select Installation on the boot screen and press [Enter]. This loads the openSUSE installation program and starts the installation in normal mode. 3 Select the language and the keyboard layout to be used during the installation and for the installed system. Read the License Agreement and proceed with Next if you agree. If you do not agree, press Abort to terminate the installation.
4 Select New Installation and proceed with Next. 5 Either use the map or the drop down lists for Region and Time Zone to select the clock and time zone to use in your system. Proceed with Next.
6 Select the desktop system you would like to use. KDE and GNOME, are powerful graphical desktop environments similar to Windows, alternative selections are available when checking Other. Proceed with Next. 7 Define a partition setup for openSUSE in this step. In most cases a reasonable scheme that can be accepted without change is proposed. Accept the proposal with Next and proceed with the installation.
8 Type your first and last name in the User’s Full Name field, your login name in the Username field, and your password in the Password field. For security reasons, your password should be at least eight characters long and should contain uppercase and lowercase letters and numbers. Passwords are case-sensitive. Proceed with Next. By default, the password you enter here is also used for the system administrator, root.
9 Type a password for the system administrator account (called the root user). This step is skipped in case you had activated Use this Password for System Administrator in the previous step. You should never forget the root password. After you enter it here, the password cannot be retrieved. It can only be reset with administrative assistance. Proceed with Next. 10 Use the Installation Settings screen to review your choices as well as some automatically proposed settings. If necessary, change the settings.
11 Click Install to start the installation. 12 The installation usually takes between 15 and 30 minutes, depending on the system performance and the selected software scope. During the installation you may either view the product presentation, the release notes containing last-minute information, or the detailed installation log.
14 If you have chosen the automatic login function, the desktop directly starts. Otherwise you will see the login screen. Click on your username, and type your password in the Password field. Press [Enter] to login.
2 KDE Quick Start openSUSE® provides the tools that Linux* users require in their daily activities. It comes with an easy-to-use graphical environment, the KDE* desktop, that communicates with the underlying Linux system to access and manage files, folders, and programs. openSUSE provides an integrated suite of applications for a wide range of purposes (office, multimedia, Internet). The LibreOffice suite is also included, which allows you to edit and save files in a number of formats.
Desktop Context Menu: Right-click an empty area on the desktop to access the context menu for configuring the appearance of the desktop, adding panels or widgets to the desktop, configuring desktop settings, locking the widgets in their current position, leaving the current session, or for locking the screen. Desktop Toolbox: Move your mouse pointer to the icon in the upper right corner of the desktop to access the menu that lets you add or lock widgets.
If you often need a program and do not want to dig into the menu structure, you can integrate the icon into the Favorites tab. Right-click the icon on any of the other tabs and choose Add to Favorites. 2.2.2 Using the Run Command Dialog KRunner is a helper application that lets you quickly start programs. Apart from that, it offers a search function for finding applications or locations. Press [Alt] + [F2] to open the Run Command dialog. Type a command, for example, dolphin.
The Run Command dialog allows you also to use different features. Click on the question mark icon to see a list of active features. To configure or get a list of all features, click on the wrench icon. You can use so-called Web shortcuts defined in Konqueror to send search requests directly to a search engine without first opening the browser. Another interesting feature is to calculate a mathematical expression like =2+2^4-sin(2).
For example, if you plugged in a digital camera, the actions allow you to download your photos with Gwenview or digiKam. Click the device entry in the widget to access the available actions. To safely remove the device from your computer, use the icon on the right side of the device entry. 2.4 Customizing Your Desktop You can change the way your KDE desktop looks and behaves to suit your personal preferences. 2.4.
2 Right-click and select Add to Desktop from the context menu that appears. If this menu item is not available, your desktop elements are probably locked. Unlock them first as described in Section 2.4.1, “Locking and Unlocking Desktop Objects” (page 15). 3 To change the icon position on the desktop, left-click the icon and drag it to the desired position. To delete an icon from your desktop, right-click the program icon and select Remove this Icon. Procedure 2.
If the frame does not appear, your widgets are probably locked. Unlock them first as described in Section 2.4.1, “Locking and Unlocking Desktop Objects” (page 15). 2 To change the widget size, left-click the scale symbol in the frame and keep the mouse button pressed while slowly moving your cursor across the desktop. 3 To rotate the widget in any direction, left-click the arrow symbol in the frame and keep the mouse button pressed while moving your cursor in a circle across the desktop.
2 To move panel objects to a different place within the panel, hover the mouse cursor over the respective panel object (for example, program icon, pager, task manager, system tray). The mouse cursor turns into a crosslines-like form. Click the object and move the cursor to the desired position in the panel. Click again to fix it at this place. 3 To enlarge the distance between two widgets, use Add Spacer.... A spacer widget appears on the right side. Drag and drop it to the preferred place.
2 In the View section, choose a type from the Wallpaper drop-down list. The further configuration options depend on the choice of the object to use as background. 3 For example, to use an image wallpaper: 3a Set Wallpaper to Image. 3b Define the Positioning of the image. 3c To use one of the available wallpapers, either choose a wallpaper from the list or click Get New Wallpapers to download additional wallpapers. 3d To use a custom picture, click Open and select an image file from the file system.
The settings are grouped into different categories. Hover over an icon to see more details. Performing tasks in some areas of the personal settings requires system administrator (root) permissions. Change the settings as desired. No changes take effect until you click Apply. To discard changes in the recent view that you have not yet applied, click Reset. To reset all items in the recent view to the default values, click Defaults.
1 Start the System Settings as described in Section 2.4.3, “Modifying Personal Settings” (page 19). 2 Select Desktop Effects from the Workspace Appearance and Behavior category and choose Enable Desktop Effects. If your graphic card does not support 3D, you will be notified. 3 Optionally, change some options below Common Settings. 4 On the All Effects tab, select the effects you want to activate. Click the information icon for a short explanation of the respective effect.
2 For any configuration options, right-click the pager and select Pager Settings. 3 Use the options on the General screen to configure the appearance of the pager in the panel. 4 Desktop names, keyboard shortcuts for switching desktops and the switching type can be configured on the Virtual Desktops screen. 5 Set the options according to your wishes and click OK to apply the changes and to close the configuration dialog. 2.
Menu Bar: The menu bar holds menu items for actions like copying, moving, or deleting files, changing views, starting additional tools, defining your settings, and getting help. Toolbar: The toolbar provides quick access to frequently used functions that can also be accessed via the menu. If you hover the mouse pointer over an icon, a short description is displayed. Location Bar: The location bar displays the path to the current directory.
To copy, move, or delete a file or folder, proceed as follows: 1 In order to select one or multiple files and folders in Dolphin, move your mouse pointer over the file or folder but do not click. A green cross appears on the upper-left edge. If you click it, the object is selected. To deselect again, click the red minus icon that appears if the object is currently selected. Alternatively, press [Ctrl] and click the objects you want to select or deselect.
2 To change the view of the currently displayed folder, either click Icons, Details, or Columns in the toolbar. Dolphin remembers the selected view for each folder. Click Split or press [F3] to view the contents of the current folder in two separate columns. Now you can navigate to a different directory in each column and easily drag or drop objects or compare the contents of directories. Press [F3] again to leave the split view. 3 To make Dolphin also show hidden files, select View > Show Hidden Files.
1 To use the same view mode for all folders, click General in the left sidebar and activate Use Common View Properties for All Folders. Click View Modes in the left sidebar and adjust the options for the individual view modes. Click Apply to save the changes. 2 If you want Dolphin to show a different directory on start-up, or if you want to permanently use the editable location bar instead of the bread crumb view, click Startup in the left sidebar and change the relevant options.
one or all existing tabs, or close them. You can also change the sequence of the tabs by dragging and dropping them to the desired position. 2.8.1 Finding Information Both browsers offer different kinds of search options: you can find information on the Web or you can search the current Web page for keywords. Procedure 2.11 Searching the Web 1 To start a search on the Web, click the left icon in the search bar (located next to the location bar) to open a list of search engines.
You might also want to configure the Web shortcuts you can use with Konqueror (and the Run Command dialog). In the Konqueror configuration dialog, click Web Shortcuts to see which shortcuts are already defined. Click New to define new shortcuts. Leave the Konqueror configuration dialog with OK to apply your changes. In Firefox, select Edit > Preferences to open the Firefox Preferences. Click the icons in the upper display field to access the options for the relevant category.
To activate KWallet, select Basic Setup and click Next. Select Yes, I wish to use the KDE wallet to store my personal information and enter a password. This is your master password for the default wallet (named kdewallet) that is created during the next step. WARNING: Protect Your KWallet Password If you forget your master password for any wallet, it cannot be recovered. Furthermore, anyone who knows your master password can obtain all information contained in the respective wallet.
2.10 E-Mailing and Calendaring For reading and managing your mails and appointments, you can use Kontact as your personal information management tool (PIM). Kontact combines KDE applications like KMail, KOrganizer, and KAddressBook into a single interface. This gives you easy access to your e-mails, calendar, address book, and other PIM functionality. Kontact can also manage multiple e-mail accounts. 2.10.1 Starting Kontact for the First Time To start Kontact, press [Alt] + [F2] and enter kontact.
To write a new mail, click the Mail icon in the Kontact main window and press [Ctrl] + [N] to open the mail composer. After you have finished your mail, click Send to send it immediately. In case you have configured multiple e-mail accounts, keep the Send button pressed, then select the account from which you want to send the mail. 2.11 Instant Messaging with Kopete Kopete is an online messenger application that allows multiple partners connected to the Internet to chat with each other.
2.12 Starting LibreOffice The office suite LibreOffice offers a complete set of office tools, including word processor, spreadsheet, presentation, vector drawing, and database components. Because LibreOffice is available for a number of operating systems, you can use the same data across different computing platforms. To start LibreOffice press [Alt] + [F2] and enter libreoffice. To create a new document, select File > New and choose the type of document to create.
bottom of the window. Depending on which icon you click on the navigation panel on the left, the sidebar either shows a table of Contents, a Thumbnail view of each page, the Reviews, or your Bookmarks for this file. To filter for any text listed in the sidebar or the overall document, enter a string into the input field at the top of the sidebar. If you want to select and copy text or images from the file in Okular, click the Selection icon in the toolbar and select one of the options from the context menu.
2.13.2 Using Acrobat Reader If Acrobat Reader is not installed by default, install the acroread package with YaST. To start Acrobat reader, press [Alt] + [F2] and enter acroread. Click File > Open, locate the desired PDF file and click Open to view the file. 2.14 Searching for Data KDE provides more than one application for finding data on your computer or in the file system. One application is KFind, which is described below. 2.14.1 Using KFind To perform basic and advanced searches, use KFind.
4 Click Find to start the search. 2.14.2 Using Strigi Desktop Search Strigi Desktop Search offers advanced search capabilities,by additionally searching for metadata such as tags, ratings, and even source URLs for downloads. It requires the services nepomuk and strigi to run. To activate these services, press [Alt] + [F2] and enter strigi. Choose Nepomuk/Strigi server Configuration to start the configuration dialog.
4 Insert a writable CD or DVD into the device then click the Burn icon. 5 Check the settings on the Writing tab. Usually the defaults should work well for almost all files. If you wish, you can change more options (for example the Volume Name) on the Filesystem tab. 6 Click Burn. 2.
digiKam's main window contains a tree view on the left and shows thumbnails of the images on the right. For quick access to your images, use the sidebar on the left, which allows you to switch between different views, for example, sorting the images according to Albums, Dates, Tags or Searches. To enter digiKam's viewing and editing mode, double-click an image thumbnail. 2.
Amarok's main window shows a sidebar on the left providing different views: your local music collection, some addresses to listen to podcasts or streams from the Internet, your playlists and a file browser. The middle part, the context browser, displays information about the current track, the Wikipedia page of the artist and the song's lyrics by default. The right part of the window shows the current playlist. To play music, just drag and drop items from any of the sidebar browsers to the playlist area.
2.19 For More Information To learn more about KDE and KDE applications, also refer to http://www.kde.org/ and http://www.kde-apps.org/.
3 GNOME Quick Start openSUSE® provides the tools that Linux* users require in their daily activities. It comes with an easy-to-use graphical environment, the GNOME* desktop, that communicates with the underlying Linux system, to let you access and manage files, folders, and programs. openSUSE provides an integrated suite of applications for a wide range of office, multimedia, and Internet activities. The LibreOffice suite, which allows you to edit and save files in a number of formats, is also included.
can for deleted items. Other icons representing devices on your computer, such as CD drives or USB flash disks, may also be present on the desktop, and you can add as many icons on your desktop as you like. If you double-click your Home folder, the Nautilus file manager starts and displays the contents of your home directory. Bottom Panel: The desktop includes a panel at the bottom of the screen.
2 Browse to the desired program and double-click it to add it to the panel. 3 To remove a program icon from a panel, right-click its icon in the panel and select Remove From Panel. 3.2 Starting Programs Start programs from the Main Menu or from the command line, using a shell or the Run Command. Additionally, you can start programs from the desktop or the panel by left-clicking the program icon once. 3.2.
3.2.2 Using the Run Application Dialog Press [Alt] + [F2] to open the Run Application dialog. Type a command, for example, f-spot, and press [Enter] or click Run to start the application. The command to start the application is often (but not always) the application name written in lowercase. 3.3 Handling Media If you insert a CD or DVD into your drive or plug in a pluggable device (for example, a USB stick or removable hard disk), GNOME opens Nautilus and shows the content of the media. 3.
2 Select Change Desktop Background. 3 To select a wallpaper from the pre-installed images, browse to and select the desired image. After you select it, the background changes automatically. 4 To add an image, select Add, browse to the desired image, then click Open. 5 To display a colored background, select the solid color rectangle from the top of the list; then, from Colors, select the fill pattern and the desired colors. 6 Click Close. 3.4.
3.5 Applying Desktop Effects If your computer supports a 3D graphics card with Xgl, you can use graphical effects like turning your desktop into a rotating 3D cube, enabling translucent or transparent windows, and zooming in and out of the desktop screen. You can also use other window effects such as shadows, fading, and transformations. If you do not have a 3D graphics card, some effects may be disabled or reduce the performance of your system.
1 Start the personal settings window as described in Section 3.4.3, “Using the GNOME Control Center” (page 45). 2 Select Look and Feel > Desktop Effects and choose Enable Desktop Effects. If your graphic card does not support 3D, you will be notified. 3 Select the effects in one of the tabs. 3.6 Using Virtual Desktops The desktop environment allows you to organize your programs and tasks on several virtual desktops.
2 Decrease or increase the Number of Workspaces. 3 If you want to change the names of the desktops double click on the list entries and enter the new names. 3.7 Managing Files and Folders Use the Nautilus File Manager to create and view folders and documents, run scripts, and create CDs of your data. To open Nautilus, double-click your home directory icon on the desktop. You see the contents of your home directory.
Toolbar Lets you quickly navigate among files and folders, and provides access to files and folders. Location Bar Lets you locate files, folders, and URI sites. If you prefer text based location display to the button based one, select Go > Location. Side Pane Lets you navigate or display information about the selected file or folder. Use the drop-down list to customize what is shown in the pane.
1 Open the folder you want to create a bookmark for. 2 Click Bookmarks > Add Bookmark. The bookmark is added to the list, with the folder name as the bookmark name. 3 To select an item from your bookmarks list, click Bookmarks, then click the desired bookmark in the list. You can also organize your bookmarks list by clicking Bookmarks > Edit Bookmarks and making your selections in the dialog box.
To open a new empty tab in Firefox, press [Ctrl] + [T] or the “+” button next to the last tab . Type a new URL to browse. To open a link in a new tab, click the link with your middle mouse button. Right-click a tab to access more tab options. You can create a new tab, reload one or all existing tabs, or close a single tab or all tabs. You can also change the sequence of the tabs by dragging and dropping them to a new position. 3.8.
Here also configure many other settings such as appearance, language, privacy, and tab options. Click the icons and set the options on each page according to your preferences. Click Close to apply the changes. 3.9 Managing Passwords GNOME allows you to store your passwords and encryption keys in a keyring. This is useful if you want to store passwords for different web sites. To create a new keyring, proceed as follows: 1 Press [Alt] + [F2] and enter seahorse. 2 Select File > New.
3.10 E-Mailing and Calendaring For reading and managing your mail and events, openSUSE offers you Evolution™, a groupware program that makes it easy to store, organize, and retrieve your personal information. Evolution seamlessly combines an e-mail, a calendar, an address book, and a task list in one easy-to-use application. With its extensive support for communications and data interchange standards, Evolution can work with existing corporate networks and applications, including Microsoft* Exchange.
To start Empathy, click Computer > More Applications > Internet > Empathy, or press [Alt] + [F2] and enter empathy. To add an account to Empathy, either use the initial configuration wizard, or select Edit > Accounts. Click Add and select the protocol you want to use, and type your login information in the appropriate fields. Click Log in to activate you IM account. Finally click Close to start chatting with your friends. Add contacts by clicking Chat > Add Contanct.
2 Use the navigation icons at the top of the window to navigate through the document. If the PDF document provides bookmarks, you can access them in the left panel of the viewer. 3.14 Searching for Data GNOME provides more than one application for finding data on your computer or in the file system. 3.14.1 Using Desktop Search To locate files or programs on your computer, click Computer. Enter a search term in the Search field and press [Enter]. The results are displayed in the Needle.
3.14.2 Using GNOME Do GNOME Do describes itself as an “intelligent launcher that makes performing common tasks on your computer simple and efficient.” It is extensible with plug-ins. Start it by pressing [Super] + [Space]. The [Super] is normally located on the left and right [Windows] or [Penguin] key. GNOME Do allows you to perform specific actions.
3.15 Creating a CD or DVD If your system has a CD or DVD writer, use the Nautilus file manager to burn CDs and DVDs. 1 Click Computer > More Applications > System Tools > CD/DVD Creator, or just insert a blank disk. 2 Copy the files and folders you want to put on the CD or DVD into the Nautilus CD/DVD Creator window. 3 Click Write to Disk. 4 Modify the relevant information in the Write to Disk dialog box, or accept the default values, then click Write. The files are burned to the disk.
To access F-Spot, click Computer > F-Spot Photo Browser or press [Alt] + [F2] and enter f-spot. The first time you run F-Spot, you must define the location from where you want to import images into your collection. If you already have a collection of images stored on your hard drive, enter the path to the directory and (optionally) include subfolders. F-Spot imports these images into its database.
Choose an import source and click Import. After successfully importing your media, you can access them from your library. To play a song or a movie, simply select it in the library and click the play button. You can also use the buttons in the upper left corner to pause a song or play the next or previous song. Use the loudspeaker button on the right to adjust the volume. Banshee also has an integrated CD player. When you insert a music CD, your CD title appears in the left panel.
3.18.2 Restarting or Shutting Down the Computer Click Computer > Shutdown, then select one of the following options: Shutdown Logs you out of the current session, then turns off the computer. Restart Logs you out of the current session, then restarts the computer. Suspend Puts your computer in a temporary state that conserves power. The state of your session is preserved, however, including all applications you have running and all documents you have open.
4 LibreOffice Quick Start LibreOffice—formerly known as OpenOffice.org—is a powerful open-source office suite that provides tools for all types of office tasks such as writing texts, working with spreadsheets, creating graphics and presentations, or designing scientific formulas. With LibreOffice, you can use the same data across different computing platforms. You can also open and edit files in other formats, including Microsoft Office, then save them back to this format.
Module Usage Base Database module Draw Vector graphics module Math Mathematical equation module 4.3 What is New in LibreOffice A number of new improvements common to all LibreOffice modules were introduced since the last openSUSE release. Here are the most notable ones: Common Search Toolbar A unified search toolbar is now present in each LibreOffice module to ease searching for a text string within open documents. You can toggle the toolbar with View > Toolbars > Find.
4.4 Starting LibreOffice To start the LibreOffice suite, press [Alt] + [F2], type libreoffice and press [Enter]. In the Welcome dialog, select the module you want to open. If an LibreOffice application is open, you can start any of the other applications by clicking File > New > Name of Application. 4.4.1 Saving LibreOffice Files 1 To save a new file, select File > Save or Save as from the Menu Bar or use the shortcut [Ctrl] + [Shift] + [S]. 2 Select the directory where you want to save the file.
to get a quick overview of all images included in the document. To open the Navigator, click View > Navigator or with [F5]. The elements listed in the Navigator vary according to the LibreOffice module being used. You can also navigate your files with the following shortcuts: Table 4.
5 Click OK. 4.5 LibreOffice Writer LibreOffice Writer is a full-featured word processor with page and text-formatting capabilities. It also includes some features that are usually found only in expensive desktop publishing applications. Many of the LibreOffice Writer features apply also to other LibreOffice modules. 4.5.
Inserting Headers and Footers If you want to add headers and footers, click Insert and select either Header or Footer. Inserting Special Characters If you want to insert special characters, select Insert > Special Character. Inserting Footnotes If you want to insert footnotes, click Insert and select Footnote. Inserting Columns If you want to insert columns, click Insert and select Section. Then in the Columns tab, specify the number of columns to use for the current section.
in a single file. A master document enables you to quickly apply formatting changes to a large document or to jump to each subdocument for editing. A master document is a Writer document that serves as a container for multiple Writer files. You can maintain chapters or other subdocuments as individual files collected in the master document. Master documents are also useful if multiple people are working on a document.
HTML Source mode, the Formatting and Styles list is not available. The first time you switch to HTML Source mode, you are prompted to save the file as HTML, if you have not already done so. 4.5.5 Tables You can include tabular data in the Writer, Impress and Draw module. Insert basic tables directly into your document either with the following menus items or by using the toolbar: • Insert > Table, • Table > Insert > Table, • or use the Table icon.
4.6.1 Creating a New Document Start LibreOffice and select File > New > Spreadsheet to create a new spreadsheet. Access the individual sheets by clicking the respective tabs at the bottom of the window. Enter data in the cells as desired. To adjust appearance, either use the Formatting toolbar or the Format menu—or define styles. Use the File menu or the relevant buttons in the toolbar to print and save your document. 4.6.
4 Specify a name for your style and use the various tabs to set the desired formatting options. 5 Click OK. Procedure 4.2 Modifying a Style 1 Click Format > Styles and Formatting. 2 In the Styles and Formatting window, click either the Cell Styles or the Page Styles icon. 3 Right-click the name of the style you want to change, then click Modify. 4 Change the desired formatting options. 5 Click OK. 4.
4.7.2 Using Databases with Base LibreOffice includes a database module (Base). Use Base to design a database to store many different kinds of information, from a simple address book or recipe file to a sophisticated document management system. Tables, forms, queries, and reports can be created manually or using convenient wizards. For example, the Table Wizard contains a number of common fields for business and personal use. A wizard guides you through the steps to create a new database.
Procedure 4.4 Setting Up the Database Table 1 In the Table Wizard, click Personal. 2 The Sample tables list changes to show the predefined tables for personal use. If you had clicked Business, the list would contain predefined business tables. In the Sample tables list, click Addresses. The available fields for the predefined address book appear in the Available fields menu. 3 In the Available fields menu, click the fields you want to use in your address book.
LibreOffice allows you to import Scalable Vector Graphics (*.svg) and WordPerfect Graphics (*.wpg). Select File > Open and use the Filter drop-down list to view which file formats can be opened. Procedure 4.5 Creating a Graphic 1 Click [Alt] + [F2] and enter oodraw to open LibreOffice Draw. 2 Use the toolbar at the bottom of the window to create a graphic. 3 Save the graphic. To embed an existing Draw graphic into an LibreOffice document, select Insert > Object > OLE Object.
NOTE Math is not a calculator. The functions it creates are graphical objects. Even if they are imported into Calc, these functions cannot be evaluated. 4.8 For More Information LibreOffice also contains extensive online help. In addition, a large community of users and developers support it. For more details, see the following links: http://www.libreoffice.org/download/3-4-new-features-and-fixes/ A list of all new features available with LibreOffice. http://www.libreoffice.
Part II.
5 Installing or Removing Software Use YaST's software management tool to search for software components you want to add or remove. YaST resolves all dependencies for you. To install packages not shipped with the installation media, add additional software repositories to your setup and let YaST manage them. Keep your system up-to-date by managing software updates with the update applet. Change the software collection of your system with YaST Software Manager.
Product Represents a whole product, for example openSUSE®. Pattern A pattern is an installable group of packages dedicated to a certain purpose. For example, the Laptop pattern contains all packages that are needed in a mobile computing environment. Patterns define package dependencies (such as required or recommended packages) and come with a preselection of packages marked for installation.
5.2.1 Views for Searching Packages or Patterns The YaST software manager can install packages or patterns from all currently enabled repositories. It offers different views and filters to make it easier to find the software you are searching for. The Search view is the default view of the window. To change view, click View and select one of the following entries from the drop-down list. The selected view opens in a new tab. Patterns Lists all patterns available for installation on your system.
Installation Summary If you have already selected packages for installation, update or removal, this view shows the changes that will be applied to your system as soon as you click Accept. To filter for packages with a certain status in this view, activate or deactivate the respective check boxes. Hit [Shift] + [F1] for details on the status flags.
6 Before applying your changes, you can review or modify them by clicking View > Installation Summary. By default, all packages that will change status, are listed. 7 In order to revert the status for a package, right-click the package and select one of the following entries: Keep if the package was scheduled to be deleted or updated, or Do Not Install if it was scheduled for installation.
comparable package can be found, all packages are considered and the “best” update candidate is selected according to the following criteria: 1. Repository priority: Prefer the package from the repository with the highest priority. 2. If more than one package results from this selection, choose the one with the “best” architecture (best choice: matching the architecture of the installed one; otherwise: x86_64 > i686 > i586).
5.2.4 Checking Software Dependencies Most packages are dependent on other packages. If a package, for example, uses a shared library, it is dependent on the package providing this library. On the other hand some packages cannot coexist with each other, causing a conflict (for example, you can only install one mail transfer agent: sendmail or postfix). When installing or removing software, the Software Manager makes sure no dependencies or conflicts remain unsolved to ensure system integrity.
Figure 5.1 Conflict Management of the Software Manager 5.3 Using the GNOME Interface (GTK+) The YaST GTK+ interface is started by default when using the desktops GNOME and XFCE. Start the software manager from the YaST Control Center by clicking Software > Software Management. 5.3.1 Views for Searching Packages or Patterns The easiest way to find a package is to use the search field in the upper right corner of the software manager. Enter a search term and press [Enter].
search package names and summaries. Press the search item to change this filter and search the file lists, for example. The software manager also offers different views and filters for displaying package lists. These are available from the pull-down menu in the upper left corner: Groups The default view lists all packages sorted by groups such as Admin Tools, Graphics, Programming, or Security. RPM Groups Lists all packages sorted by functionality with groups and subgroups.
To mark a package for installation, re-installation, removal, or upgrade, rightclick the package and choose the appropriate action from the menu. TIP: Applying an Action to All Packages Listed To apply an action to all packages listed in the right pane, right-click a package, choose Select All, right-click again and choose an action. 3 To install a pattern, right-click the pattern name and choose Install. 4 It is not possible to remove a pattern per se.
• package vendor. Which of the aspects has the highest importance for choosing the update candidates depends on the respective update option you choose. 1 To view the list of packages that can be updated (packages with higher versions are available), select Upgradable in the bottom left box. 2 To update all packages listed there, click Upgrade All. To install only upgradable packages for which an official patch has been issued, click Upgrade Patches.
In case there exists only one solution to resolve a dependency or a conflict, it is resolved automatically. Multiple solutions always cause a conflict which needs to be resolved manually. If solving a conflict involves a vendor or architecture change, it also needs to be solved manually. When clicking Apply to apply any changes in the Software Manager, you get an overview of all actions triggered by the automatic resolver which you need to confirm. By default, dependencies are automatically checked.
To manage repositories, start YaST and select Software > Software Repositories. The Configured Software Repositories dialog opens. Here, you can also manage subscriptions to so-called Services by changing the View at the right corner of the dialog to All Services. A Service in this context is a Repository Index Service (RIS) that can offer one or more software repositories. Such a Service can be changed dynamically by its administrator or vendor.
After confirming these messages, YaST will download and parse the metadata and add the repository to the list of Configured Repositories.. 6 If needed, adjust the repository Properties as described in Section 5.4.2, “Managing Repository Properties” (page 90) or confirm your changes with OK to close the configuration dialog. Now you can install software from this repository as described in Section 5.2, “Using the KDE Interface (Qt)” (page 78) or in Section 5.3, “Using the GNOME Interface (GTK+)” (page 84).
once for static repositories such as CDs or DVDs, whereas repositories whose content changes often should be refreshed frequently. The easiest way to keep a repository's cache up-to-date is to choose Automatically Refresh. To do a manual refresh click Refresh and select one of the options. Keep Downloaded Packages Packages from remote repositories are downloaded before being installed. By default, they are deleted upon a successful installation.
To manage all imported keys, click GPG Keys... in the Configured Software Repositories dialog. Select an entry with the mouse to show the key properties at the bottom of the window. Add, Edit or Delete keys with a click on the respective buttons. 5.5 Keeping the System Up-to-date openSUSE offers a continuous stream of software security patches for your product. The update applet informs you about the availability of patches and lets you easily install them with just a few clicks. 5.5.
Figure 5.3 KDE Software Updater The YaST Online Update offers advanced features to customize the patch installation. Please refer to Chapter 6, YaST Online Update (page 97) for more information. 5.5.1.2 Configuring the KDE Software Updater By default Software Updater checks for updates every 24 hours, notifies you when patches are available and does not automatically install patches. These settings can be changed with the Software Management settings.
Open box with a globe The update applet is busy (for example checking for updates or installing software). Red Star with Exclamation Mark Security patches are available. Orange Star with an Up Arrow Important patches are available. Yellow Star with a Down Arrow Trivial patches are available. Yellow Triangle with Exclamation Mark An error has occurred. 5.5.2.1 Installing Patches Procedure 5.
Figure 5.4 GNOME Update Applet The YaST Online Update offers advanced features to customize the patch installation. Please refer to Chapter 6, YaST Online Update (page 97) for more information. 5.5.2.2 Configuring the Software Update Applet To configure the update applet, right-click the update icon in the panel and choose Preferences. The configuration dialog lets you modify the following settings: Check for Updates Choose how often a check for updates is performed: Hourly, Daily, Weekly, or Never.
6 YaST Online Update openSUSE offers a continuous stream of software security updates for your product. By default, the update applet is used to keep your system up-to-date. Refer to Section 5.5, “Keeping the System Up-to-date” (page 92) for further information on the update applet. This chapter covers the alternative tool for updating software packages: YaST Online Update.
Figure 6.1 YaST Online Update—Qt Interface The Summary section on the left lists the available patches for openSUSE. The patches are sorted by security relevance: security, recommended, and optional. You can change the view of the Summary section by selecting one of the following options from Show Patch Category: Needed Patches (default view) Non-installed patches that apply to packages installed on your system.
Select an entry in the Summary section to view a short Patch Description at the bottom left corner of the dialog. The upper right section lists the packages included in the selected patch (a patch can consist of several packages). Click an entry in the upper right section to view details about the respective package that is included in the patch. 6.1.2 GNOME Interface (GTK) The Online Update window consists of four main sections. Figure 6.
versions available. You can also choose to Install optional patches—security and recommended patches are already preselected for installation. 6.2 Installing Patches The YaST Online Update dialog allows you to either install all available patches at one go or to manually select the patches that you want to apply to your system. You may also revert patches that have been applied to the system.
TIP: Disabling deltarpms By default updates are downloaded as deltarpms. Since rebuilding rpm packages from deltarpms is a memory and CPU time consuming task, certain setups or hardware configurations might require you to disable the usage of deltarpms for performance sake. To disable the use of deltarpms edit the file /etc/zypp/zypp.conf and set download.use_deltarpm to false. 6.3 Automatic Online Update YaST also offers the possibility to set up an automatic update with daily, weekly or monthly schedule.
7 Installing Packages From the Internet By default, it is only possible to install packages from configured and enabled repositories. Apart from the official repositories that are configured during the installation, numerous other repositories exist. The openSUSE® Build Service hosts several hundred ones and a lot of third party repositories exist, too—see http://en.opensuse .org/Additional_package_repositories.
5 Click Search. 6 From the results list select the preferred item by clicking its 1-Click Install button. 7 In the Web browser's download dialog, select to open the file with the YaST Meta Package Handler. The 1-click installer opens the Additional Software Repositories dialog. It shows the repositories providing the packages you want to install per 1-Click Install. They are activated per default. To proceed with the installation, keep the repository selection.
Procedure 7.2 Installing Packages Using the YaST Package Search 1 Start the Package Search from the YaST Control Center via Software > Package Search. 2 Search for a software package by entering it's name into the Search Expression field and clicking Search. 3 The search result is listed on the Found Packages tab. Click on a package name to see the repository URL, the package version number and the architecture in the Package Description pane.
8 Installing Add-On Products Add-on products are system extensions. You can install a third party add-on product or a special system extension of openSUSE® (for example, a CD with support for additional languages or a CD with binary drivers). To install a new add-on, start YaST and select Software > Add-On Products . You can select various types of product media, like CD, FTP, USB mass storage devices (such as USB flash drives or disks) or a local directory. You can work also directly with ISO files.
9 After having successfully added the repository for the add-on media, the software manager starts and you can install packages. Refer to Chapter 5, Installing or Removing Software (page 77) for details. 8.2 Binary Drivers Some hardware needs binary-only drivers to function properly. If you have such hardware, refer to the release notes for more information about availability of binary drivers for your system. To read the release notes, open YaST and select Miscellaneous > Release Notes.
9 Managing Software with Command Line Tools This chapter describes Zypper and RPM, two command line tools for managing software. For a definition of the terminology used in this context (for example, repository, patch, or update) refer to Section 5.1, “Definition of Terms” (page 77). 9.1 Using Zypper Zypper is a command line package manager for installing, updating and removing packages as well as for managing repositories.
Some options also require an argument. The following command will list all known patterns: zypper search -t pattern You can combine all of the above. For example, the following command will install the mplayer and amarok packages from the factory repository while being verbose: zypper -v install --from factory mplayer amarok The --from option makes sure to keep all repositories enabled (for solving any dependencies) while requesting the package from the specified repository.
by capability and/or architecture and/or version Together with a capability you can specify an architecture (such as i586 or x86_64) and/or a version. The version must be preceded by an operator: < (lesser than), <= (lesser than or equal), = (equal), >= (greater than or equal), > (greater than). zypper install 'firefox.x86_64' zypper install 'firefox>=3.5.3' zypper install 'firefox.x86_64>=3.5.
WARNING: Do not Remove Mandatory System Packages Do not remove packages such as glibc, zypper, kernel, or similar packages. These packages are mandatory for the system and, if removed, may cause the system to become unstable or stop working altogether. 9.1.2.1 Installing Source Packages If you want to install the corresponding source package of a package, use: zypper source-install package_name That command will also install the build dependencies of the specified package.
tion. The latter is achieved with the zypper dist-upgrade command which is discussed in Section 16.1, “Upgrading the System” (page 181). 9.1.3.1 Installing Patches To install all officially released patches applying to your system, just run: zypper patch In this case, all patches available in your repositories are checked for relevance and installed, if necessary. The above command is all you must enter in order to apply them when needed.
zypper patch --bugzilla=number or zypper patch --cve=number For example, to install a security patch with the CVE number CVE-2010-2713, execute: zypper patch --cve=CVE-2010-2713 9.1.3.2 Installing Updates If a repository contains only new packages, but does not provide patches, zypper patch does not show any effect.
the repositories currently enabled. For detailed instructions, refer to Section 16.1.4, “Distribution Upgrade with zypper” (page 183). To restrict the distribution upgrade to packages from a certain repository while considering also the other repositories for satisfying dependencies, use the --from option and specify the repository by either its alias, its number or URI.
zypper repos -d 9.1.4.1 Adding Repositories To add a repository, run zypper addrepo URIalias URI can either be an Internet repository, a network resource, a directory or a CD or DVD (see http://en.opensuse.org/openSUSE:Libzypp_URIs for details). The alias is a shorthand and unique identifier of the repository. You can freely choose it, with the only exception that is has to be unique. Zypper will issue a warning if you specify an alias that is already in use. 9.1.4.
zypper zypper zypper zypper products patterns packages patches To query all repositories for certain packages, use search. It works on package names, or, optionally, on package summaries and descriptions. Using the wildcards * and ? with the search term is allowed. By default, the search is not case-sensitive.
zypper refresh -fdb This forces a complete refresh and rebuild of the database, including a forced download of raw metadata. 9.1.8 Zypper Rollback Feature on btrfs File System If the btrfs file system is used on the root partition and snapper is installed, zypper automatically calls snapper (via script installed by snapper) when committing changes to the file system to create appropriate file system snapshots. These snapshots can be used for reverting any changes made by zypper.
yourself (for example, the most recent GNOME packages). They can be identified by the name extension -devel, such as the packages alsa-devel, gimp-devel, and libkde4-devel. 9.2.1 Verifying Package Authenticity RPM packages have a GnuPG signature. To verify the signature of an RPM package, use the command rpm --checksig package-1.2.3.rpm to determine whether the package originates from Novell/SUSE or from another trustworthy facility. This is especially recommended for update packages from the Internet. 9.
Otherwise, .rpmsave is used. In other words, .rpmorig results from updating from a foreign format to RPM. .rpmsave results from updating from an older RPM to a newer RPM. .rpmnew does not disclose any information as to whether the system administrator has made any changes to the configuration file. A list of these files is available in /var/adm/rpmconfigcheck. Some configuration files (like /etc/httpd/httpd.conf) are not overwritten to allow continued operation.
rpm -qpPl pine-4.44-224.i586.patch.rpm /etc/pine.conf /etc/pine.conf.fixed /usr/bin/pine or, if the patch is already installed, with the following command: rpm -qPl pine /etc/pine.conf /etc/pine.conf.fixed /usr/bin/pine How can a patch RPM be installed in the system? Patch RPMs are used just like normal RPMs. The only difference is that a suitable RPM must already be installed.
The prepdeltarpm, writedeltarpm and applydeltarpm binaries are part of the delta RPM suite (package deltarpm) and help you create and apply delta RPM packages. With the following commands, create a delta RPM called new.delta.rpm. The following command assumes that old.rpm and new.rpm are present: prepdeltarpm -s seq -i info old.rpm > old.cpio prepdeltarpm -f new.rpm > new.cpio xdelta delta -0 old.cpio new.cpio delta writedeltarpm new.rpm delta info new.delta.
--dump File list with complete details (to be used with -l, -c, or -d) --provides List features of the package that another package can request with --requires --requires, -R Capabilities the package requires --scripts Installation scripts (preinstall, postinstall, uninstall) For example, the command rpm -q -i wget displays the information shown in Example 9.2, “rpm -q -i wget” (page 123). Example 9.2 rpm -q -i wget Name : wget Relocations: (not relocatable) Version : 1.11.
Example 9.3 Script to Search for Packages #! /bin/sh for i in $(rpm -q -a -l | grep $1); do echo "\"$i\" is in package:" rpm -q -f $i echo "" done The command rpm -q --changelog rpm displays a detailed list of change information about a specific package (in this case, the rpmpackage), sorted by date. With the help of the installed RPM database, verification checks can be made. Initiate these with -V, -y or --verify.
with gzip) and stores them in /var/adm/backup/rpmdb. The number of copies is controlled by the variable MAX_RPMDB_BACKUPS (default: 5) in /etc/sysconfig/backup. The size of a single backup is approximately 1 MB for 1 GB in /usr. 9.2.6 Installing and Compiling Source Packages All source packages carry a .src.rpm extension (source RPM). NOTE: Installed Source Packages Source packages can be copied from the installation medium to the hard disk and unpacked with YaST.
/usr/src/packages/SOURCES/wget-1.11.4.tar.bz2 /usr/src/packages/SOURCES/wgetrc.patch /usr/src/packages/SPECS/wget.spec rpmbuild -bX /usr/src/packages/SPECS/wget.spec starts the compilation. X is a wild card for various stages of the build process (see the output of --help or the RPM documentation for details). The following is merely a brief explanation: -bp Prepare sources in /usr/src/packages/BUILD: unpack and patch. -bc Do the same as -bp, but with additional compilation.
Subsequently, a minimum environment is established at /var/tmp/build-root. The package is built in this environment. Upon completion, the resulting packages are located in /var/tmp/build-root/usr/src/packages/RPMS. The build script offers a number of additional options. For example, cause the script to prefer your own RPMs, omit the initialization of the build environment or limit the rpm command to one of the above-mentioned stages.
Part III.
10 Managing Users with YaST During installation, you chose a method for user authentication. This method is either local (via /etc/passwd) or, if a network connection is established, via NIS, LDAP, Kerberos or Samba (see Section “Create New User” (Chapter 1, Installation with YaST, ↑Reference) . You can create or modify user accounts and change the authentication method with YaST at any time. Every user is assigned a system-wide user ID (UID).
Depending on the set of users you choose to view and modify with, the dialog (local users, network users, system users), the main window shows several tabs. These allow you to execute the following tasks: Managing User Accounts From the Users tab create, modify, delete or temporarily disable user accounts as described in Section 10.2, “Managing User Accounts” (page 132).
NOTE: Changing User IDs of Existing Users File ownership is bound to the user ID, not to the user name. After a user ID change, the files in the user's home directory are automatically adjusted to reflect this change. However, after an ID change, the user no longer owns the files he created elsewhere in the file system unless the file ownership for those files are manually modified. In the following, learn how to set up default user accounts.
dialog and to save the changes. A newly added user can now log in to the system using the login name and password you created. TIP: Matching User IDs For a new (local) user on a laptop which also needs to integrate into a network environment where this user already has a user ID, it is useful to match the (local) user ID to the ID in the network. This ensures that the file ownership of the files the user creates “offline” is the same as if he had created them directly on the network. Procedure 10.
10.3.2 Enforcing Password Policies On any system with multiple users, it is a good idea to enforce at least basic password security policies. Users should change their passwords regularly and use strong passwords that cannot easily be exploited. For local users, proceed as follows: Procedure 10.3 Configuring Password Settings 1 Open the YaST User and Group Administration dialog and select the Users tab. 2 Select the user for which to change the password options and click Edit.
With YaST, you can create encrypted home directories for new or existing users. To encrypt or modify encrypted home directories of already existing users, you need to know the user's current login password. By default, all existing user data is copied to the new encrypted home directory, but it is not deleted from the unencrypted directory. WARNING: Security Restrictions Encrypting a user's home directory does not provide strong security from other users.
5 Enter the user's current login password to proceed if YaST prompts for it. 6 Click Expert Options > Write Changes Now to save all changes without exiting the administration dialog. Click OK to close the administration dialog and save the changes. Procedure 10.5 Modifying or Disabling Encrypted Home Directories Of course, you can also disable the encryption of a home directory or change the size of the image file at any time. 1 Open the YaST User and Group Administration dialog in the Users view.
openSUSE allows usage of soft and hard quotas. Soft quotas usually define a warning level at which users are informed that they are nearing their limit, whereas hard quotas define the limit at which write requests are denied. Additionally, grace intervals can be defined that allow users or groups to temporarily violate their quotas by certain amounts. Procedure 10.
4 Below Size Limits, restrict the amount of disk space. Enter the number of 1 KB blocks the user or group may have on this partition. Specify a Soft Limit and a Hard Limit value. 5 Additionally, you can restrict the number of inodes the user or group may have on the partition. Below Inodes Limits, enter a Soft Limit and Hard Limit. 6 You can only define grace intervals if the user or group has already exceeded the soft limit specified for size or inodes.
to, or the access permissions of the user's home directory. You can change these default settings to meet your requirements: 1 Open the YaST User and Group Administration dialog and select the Defaults for New Users tab. 2 To change the primary group the new users should automatically belong to, select another group from Default Group. 3 To modify the secondary groups for new users, add or change groups in Secondary Groups. The group names must be separated by commas.
10.6 Managing Groups With YaST you can also easily add, modify or delete groups. Procedure 10.9 Creating and Modifying Groups 1 Open the YaST User and Group Management dialog and click the Groups tab. 2 With Set Filter define the set of groups you want to manage. The dialog shows a list of groups in the system. 3 To create a new group, click Add. 4 To modify an existing group, select the group and click Edit. 5 In the following dialog, enter or change the data.
10.7 Changing the User Authentication Method When your machine is connected to a network, you can change the authentication method you set during installation. The following options are available: NIS Users are administered centrally on a NIS server for all systems in the network. For details, see Chapter 3, Using NIS (↑Security Guide). LDAP Users are administered centrally on an LDAP server for all systems in the network. For details about LDAP, see Chapter 4, LDAP—A Directory Service (↑Security Guide).
11 Changing Language and Country Settings with YaST Working in different countries or having to work in a multilingual environment requires your computer to be set up to support this. openSUSE® can handle different locales in parallel. A locale is a set of parameters that defines the language and country settings reflected in the user interface. The main system language was selected during installation and keyboard and time zone settings were adjusted.
not belonging to your desktop framework are not affected by this change and may still appear in the language that was set in YaST. Temporarily Switching Languages for One Application Only You can also run a single application in another language (that has already been installed with YaST). To do so, start it from the command line by specifying the language code as described in Section 11.1.3, “Switching Languages for Individual Applications” (page 146). 11.1.
Procedure 11.1 Installing Additional Languages When installing additional languages, YaST also allows you to set different locale settings for the user root, see Step 4 (page 145). The option Locale Settings for User root determines how the locale variables (LC_*) in the file /etc/sysconfig/ language are set for root. You can either set them to the same locale as for normal users, keep it unaffected by any language changes or only set the variable RC_LC_CTYPE to the same values as for the normal users.
4a Set Locale Settings for User root to the desired value. For more information, click Help. 4b Decide if you want to Use UTF-8 Encoding for root or not. 5 If your locale was not included in the list of primary languages available, try specifying it with Detailed Locale Setting. However, some of these localizations may be incomplete. 6 Confirm your changes in the dialogs with OK. If you have selected secondary languages, YaST installs the localized software packages for the additional languages.
For example, to start f-spot in German, run LANG=de_DE f-spot. For other languages, use the appropriate language code. Get a list of all language codes available with the locale -av command. KDE Applications Start the application from the command line by using the following command: KDE_LANG=languageapplication For example, to start digiKam in German, run KDE_LANG=de digikam. For other languages, use the appropriate language code. 11.
• If you only run Linux on your machine, set the hardware clock to UTC and have the switch from standard time to daylight saving time performed automatically. You can change the date and time manually or opt for synchronizing your machine against an NTP server, either permanently or just for adjusting your hardware clock. Procedure 11.2 Manually Adjusting Time and Date 1 In the YaST timezone module, click Change to set date and time. 2 Select Manually and enter date and time values.
7 Confirm your changes with Accept.
12 YaST in Text Mode This section is intended for system administrators and experts who do not run an X server on their systems and depend on the text-based installation tool. It provides basic information about starting and operating YaST in text mode. YaST in text mode uses the ncurses library to provide an easy pseudo-graphical user interface. The ncurses library is installed by default. The minimum supported size of the terminal emulator in which to run YaST is 80x25 characters. Figure 12.
12.1 Navigation in Modules The following description of the control elements in the YaST modules assumes that all function keys and [Alt] key combinations work and are not assigned to different global functions. Read Section 12.2, “Restriction of Key Combinations” (page 153) for information about possible exceptions. Navigation among Buttons and Selection Lists Use [Tab] to navigate among the buttons and frames containing selection lists.
Figure 12.2 The Software Installation Module 12.2 Restriction of Key Combinations If your window manager uses global [Alt] combinations, the [Alt] combinations in YaST might not work. Keys like [Alt] or [Shift] can also be occupied by the settings of the terminal. Replacing [Alt] with [Esc] [Alt] shortcuts can be executed with [Esc] instead of [Alt]. For example, [Esc] – [H] replaces [Alt] + [H]. (First press [Esc], then press [H].
View a list of all module names available on your system with yast -l or yast --list. Start the network module, for example, with yast lan. 12.3.
13 Setting Up Hardware Components with YaST YaST allows you to configure hardware items at installation time as well as on an already-installed system. Configure audio hardware, printers or scanner support or learn which hardware components are connected to your computer by using the YaST Hardware Information module. TIP: Graphics card, monitor, mouse and keyboard settings Graphics card, monitor, mouse and keyboard can be configured with either KDE or GNOME tools. 13.
The dialog shows all sound cards that could be detected. Procedure 13.1 Configuring Sound Cards If you have added a new sound card or YaST could not automatically configure an existing sound card, follow the steps below. For configuring a new sound card, you need to know your sound card vendor and model. If in doubt, refer to your sound card documentation for the required information. For a reference list of sound cards supported by ALSA with their corresponding sound modules, see http://www.
1 Start the YaST sound module. 2 To configure a detected, but Not Configured sound card, select the respective entry from the list and click Edit. To configure a new sound card, click Add. Select your sound card vendor and model and click Next. 3 Choose one of the setup options and click Next. 4 If you have chosen Normal Setup, you can now Test your sound configuration and make adjustments to the volume. You should start at about ten percent volume to avoid damage to your hearing or the speakers.
4a Insert the original driver CD-ROM into your CD or DVD drive. 4b Select Other > Install SoundFonts to copy SF2 SoundFonts™ to your hard disk. The SoundFonts are saved in the directory /usr/share/ sfbank/creative/. 5 If you have configured more than one sound card in your system you can adjust the order of your sound cards. To set a sound card as primary device, select the sound card in the Sound Configuration and click Other > Set as the Primary Card.
6 Leave the configuration screen with OK. 13.3.1 Configuring an HP All-In-One Device An HP All-In-One device can be configured with YaST even if it is connected to the parallel port or is made available via the network. If you own a USB HP All-In-One device, start configuring as described in Procedure 13.3, “Configuring a USB or SCSI Scanner” (page 158). If it is detected properly and the Test succeeds, it is ready to use.
4 Leave with OK. The network scanner is now listed in the Scanner Configuration window and is ready to use.
14 Printer Operation openSUSE® supports printing with many types of printers, including remote network printers. Printers can be configured manually or with YaST. For configuration instructions, refer to Section 14.4, “Setting Up a Printer” (page 163). Both graphical and command line utilities are available for starting and managing print jobs. If your printer does not work as expected, refer to Section 14.8, “Troubleshooting” (page 172).
http://www.linuxfoundation.org/OpenPrinting/ The OpenPrinting home page with the printer database. The database shows the latest Linux support status. However, a Linux distribution can only integrate the drivers available at production time. Accordingly, a printer currently rated as “perfectly supported” may not have had this status when the latest openSUSE version was released. Thus, the databases may not necessarily indicate the correct status, but only provide an approximation. http://pages.cs.wisc.
WARNING: Changing Cable Connections in a Running System When connecting the printer to the machine, do not forget that only USB devices can be plugged in or unplugged during operation. To avoid damaging your system or printer, shut down the system before changing any connections that are not USB. 14.3 Installing the Software PPD (PostScript printer description) is the computer language that describes the properties, like resolution, and options, such as the availability of a duplex unit.
• The USB printer is switched off. • The communication between printer and computer is not possible. Check the cable and the plugs to make sure that the printer is properly connected. If this is the case, the problem may not be printer-related, but rather a USB related problem. Configuring a printer is basically a three-step process. First specify the connection type, then choose a driver, and name the printing queue for this setup. For many printer models, several drivers are available.
5c add a driver as described in Section 14.4.1.1, “Adding Drivers with YaST” (page 165) 6 Specify the Default paper size 7 Enter a unique name for the printer queue in the Set Arbitrary Name field. 8 The printer is now configured with the default settings and ready to use. Click OK to return to the Printer Configurations view. The newly configured printer is now visible in the printers list. 14.4.1.
Procedure 14.3 Editing a Local Printer 1 Start the YaST printer module with Hardware > Printer 2 In the Printer Configurations screen, choose a local printer from the list and click Edit. 3 Change the connection type or the driver as described in Procedure 14.1, “Adding a New Local Printer” (page 164). This should only be necessary in case you have problems with the current configuration. 4 Make this printer the default by checking Default Printer.
2 Launch the Print via Network screen from the left pane. 3 Check Accept Printer Announcements from CUPS Servers 4 Specify which servers to use under General Settings. You may accept connections from all networks available, from the local network, or from specific hosts. If you choose the latter option, you need to specify the hostnames or IP addresses, as well. 5 Confirm by clicking OK and then Yes when asked to start a local CUPS server.
4 Click OK to restart the CUPS server and return to the Printer Configurations screen. 5 Regarding CUPS and firewall settings, see http://en.opensuse.org/SDB:CUPS _and_SANE_Firewall_settings. 14.5 Network Printers A network printer can support various protocols, some of them even concurrently. Although most of the supported protocols are standardized, some manufacturers modify the standard. Manufacturers then provide drivers for only a few operating systems.
The protocol supported by the printer must be determined before configuration. If the manufacturer does not provide the needed information, the command nmap (which comes with the nmap package) can be used to ascertain the protocol. nmap checks a host for open ports. For example: nmap -p 35,137-139,515,631,9100-10000 printerIP 14.5.1 Configuring CUPS with Command Line Tools CUPS can be configured with command line tools like lpinfo, lpadmin and lpoptions.
The activated default option is identified by a preceding asterisk (*). 2 Change the option with lpadmin: lpadmin -p queue -o Resolution=600dpi 3 Check the new setting: lpoptions -p queue -l Resolution/Output Resolution: 150dpi 300dpi *600dpi When a normal user runs lpoptions, the settings are written to ~/.cups/lpoptions. However, root settings are written to /etc/cups/lpoptions. 14.
It is not recommended to set up a CUPS server in an untrusted network environment unless you take care that it is protected by special firewall rules and secure settings in the CUPS configuration. 14.7.2 PPD Files in Various Packages The YaST printer configuration sets up the queues for CUPS using the PPD files installed in /usr/share/cups/model.
14.7.2.4 PPD Files from Printer Manufacturers in the manufacturer-PPDs Package The manufacturer-PPDs package contains PPD files from printer manufacturers that are released under a sufficiently liberal license. PostScript printers should be configured with the suitable PPD file of the printer manufacturer, because this file enables the use of all functions of the PostScript printer. YaST prefers a PPD file from the manufacturer-PPDs.
14.8.2 No Suitable PPD File Available for a PostScript Printer If the manufacturer-PPDs package does not contain a suitable PPD file for a PostScript printer, it should be possible to use the PPD file from the driver CD of the printer manufacturer or download a suitable PPD file from the Web page of the printer manufacturer. If the PPD file is provided as a zip archive (.zip) or a self-extracting zip archive (.exe), unpack it with unzip. First, review the license terms of the PPD file.
14.8.4 Network Printer Connections Identifying Network Problems Connect the printer directly to the computer. For test purposes, configure the printer as a local printer. If this works, the problems are related to the network. Checking the TCP/IP Network The TCP/IP network and name resolution must be functional.
The following command can be used to test if a TCP connection can be established to cupsd (port 631) on host: netcat -z host 631 && echo ok || echo failed If the connection to cupsd cannot be established, cupsd may not be active or there may be basic network problems. lpstat -h host -l -t returns a (possibly very long) status report for all queues on host, provided the respective cupsd is active and the host accepts queries.
to send character strings or files directly to the respective port to test if the printer can be addressed on this port. 14.8.5 Defective Printouts without Error Message For the print system, the print job is completed when the CUPS back-end completes the data transfer to the recipient (printer). If further processing on the recipient fails (for example, if the printer is not able to print the printer-specific data) the print system does not notice this.
1 To stop printing, remove all paper from ink jet printers or open the paper trays of laser printers. High-quality printers have a button for canceling the current printout. 2 The print job may still be in the queue, because jobs are only removed after they are sent completely to the printer. Use lpstat -o or lpstat -h cups.example.com -o to check which queue is currently printing. Delete the print job with cancel queue-jobnumber or cancel -h cups.example.com queue-jobnumber.
15 Installing and Configuring Fonts for the Graphical User Interface The installation of additional fonts in openSUSE® is very easy. Simply copy the fonts to any directory located in the X11 font path . To the enable use of the fonts, the installation directory should be a subdirectory of the directories configured in /etc/ fonts/fonts.conf or included into this file with /etc/fonts/suse-font-dirs.conf. The following is an excerpt from /etc/fonts/fonts.conf.
SuSEconfig --module fonts executes the script /usr/sbin/fonts-config, which handles the font configuration. For more information on this script, refer to its manual page (man fonts-config). The procedure is the same for bitmap fonts, TrueType and OpenType fonts, and Type 1 (PostScript) fonts. All these font types can be installed into any directory known to fonts-config.
16 Upgrading the System and System Changes You can upgrade an existing system without completely reinstalling it. There are two types of renewing the system or parts of it: updating individual software packages and upgrading the entire system. Updating individual packages is covered in Chapter 5, Installing or Removing Software (page 77) and Chapter 6, YaST Online Update (page 97). Two ways to upgrade the system are discussed in the following sections— see Section 16.1.
16.1.2 Possible Problems If you upgrade a default system from the previous version to this version, YaST works out the necessary changes and performs them. Depending on your customizations, some steps (or the entire upgrade procedure) may fail and you must resort to copying back your backup data. Check the following issues before starting the system update. 16.1.2.1 Checking passwd and group in /etc Before upgrading the system, make sure that /etc/passwd and /etc/group do not contain any syntax errors.
4 If you added repositories during the upgrade procedure as recommended above, you now can activate those you are actually interested in. 5 In the Installation Settings dialog, adjust the settings according to your requirements. Normally, you can leave the default settings untouched. If you intend to enhance your system, however, check the packages and patterns offered in the Packages and Update Options submenus, or add support for additional languages.
16.1.4.2 The Upgrade Procedure WARNING: Check Your System Backup Before actually starting the upgrade procedure, check that your system backup is up-to-date and restorable. This is especially important because you must enter many of the following steps manually. 1 Run the online update to make sure the software management stack is upto-date. For more information, see Chapter 6, YaST Online Update (page 97). 2 Configure the repositories you want to use as an update source. Getting this right is essential.
Alternatively, you can lower the priority of these repositories. NOTE: Handling of Unresolved Dependencies zypper dup will remove all packages having unresolved dependencies, but it keeps packages of disabled repositories as long as their dependencies are satisfied. zypper dup ensures that all installed packages come from one of the available repositories. It does not consider the version, architecture, or vendor of the installed packages; thus it emulates a fresh installation.
16.2 For More Information Problems and special issues of the various versions are published online as they are identified. See the links listed below. Important updates of individual packages can be accessed using the YaST Online Update. For more information, see Chapter 6, YaST Online Update (page 97). Refer to the Product highlights (http://en.opensuse.org/Product_highlights and the Bugs article in the openSUSE wiki at http://en.opensuse.
Part IV.
17 Shell Basics When working with Linux these days, you can communicate with the system almost without ever requiring a command line interpreter (the shell). After booting your Linux system, you are usually directed to a graphical user interface that guides you through the login process and the following interactions with the operating system. The graphical user interface in Linux (the X Window System or X11) is initially configured during installation.
word and press [Enter]. The prompt now changes and shows some useful information as in the following example: ❶ ❷ ❸ tux@linux:~> ❶ Your login. ❷ The hostname of your computer. ❸ Path to the current directory. Directly after login, the current directory usually is your home directory, indicated by the ~ symbol (tilde) . When you are logged in at a remote computer the information provided by the prompt always shows you which system you are currently working on.
Also keep this in mind for commands to delete objects. Before entering a command like rm (without any option) for removing a file, you should know if you really want to get rid of the object: it will be deleted irretrievably, without confirmation. 17.2.1 Using Commands without Options In Section 17.5.1, “Permissions for User, Group and Others” (page 198) you already got to know one of the most basic commands: ls, which used to list the contents of a directory.
❻ Date and time of the last change. ❼ Name of the object. Usually, you can combine several options by prefixing only the first option with a hyphen and then write the others consecutively without a blank. For example, if you want to see all files in a directory in long listing format, you can combine the two options -l and -a (show all files) for the ls command. Executing ls -la shows also hidden files in the directory, indicated by a dot in front (for example, .hiddenfile).
shell and display the different sections, called “nodes.” Use [Space] to move forward and [<—] to move backwards. Within a node, you can also browse with [Page ↑] and [Page ↓] but only [Space] and [<—] will take you also to the previous or subsequent node. Like for the man pages, press [Q] to end the viewing mode. Note that man pages and info pages do not exist for all commands.
Relative Path Enter a path to the relevant file or directory by using the current directory as a starting point. This implies to give the levels you have to move up or down in the file system tree to reach the target directory of file, starting from the current directory. Paths contain filenames, directories or both, separated by slashes. Absolute paths always start with a slash. Relative paths do not have a slash at the beginning, but can have one or two dots.
17.3.1 Examples for Working with Files and Directories Suppose you want to copy a file located somewhere in your home directory to a subdirectory of /tmp that you need to create first. Procedure 17.1 Creating and Changing Directories From your home directory create a subdirectory in /tmp: 1 Enter mkdir /tmp/test mkdir stands for “make directory”. This command creates a new directory named test in the /tmp directory. In this case, you are using an absolute path to create the test directory.
2 To create a new, empty file named myfile.txt in the Documents directory, enter touch ~/Documents/myfile.txt Usually, the touch command updates the modification and access date for an existing file. If you use touch with a filename which does not exist in your target directory, it creates a new file. 3 Enter ls -l ~/Documents The new file should appear in the list of contents. 4 To copy the newly created file, enter cp ~/Documents/myfile.txt . Do not forget the dot at the end.
• to move a file or directory to a new location or • to do both in one step. 3 Coming to the conclusion that you do not need the file any longer, you can delete it by entering rm tuxfile.txt Bash deletes the file without any confirmation. 4 Move up one level with cd .. and check with ls -l test if the test directory is empty now. 5 If yes, you can remove the test directory by entering rmdir test 17.
The hash symbol disappears and you are acting as “normal” user again. 17.4.2 Using sudo Alternatively, you can also use sudo (superuser “do”) to execute some tasks which normally are for roots only. With sudo, administrators can grant certain users root privileges for some commands. Depending on the system configuration, users can then run root commands by entering their normal password only.
The following example shows the output of an ls -l command in a shell. This command lists the contents of a directory and shows the details for each file and folder in that directory. Example 17.
Table 17.1 Access Permissions For Files And Directories Access Permission File Folder Read (r) Users can open and read the file. Users can view the contents of the directory. Without this permission, users cannot list the contents of this directory with ls -l, for example. However, if they only have execute permission for the directory, they can nevertheless access certain files in this directory if they know of their existence.
a predefined scheme. For further details refer to Section 17.5, “File Access Permissions” (page 198). As the owner of a file or directory (and, of course, as root), you can change the access permissions to this object.
2 To grant the users group and other users write access to kde-start.xml, enter chmod go+w kde-start.xml 3 To remove write access for all users, enter chmod -w kde-start.xml If you do not specify any kind of users, the changes apply to all users— the owner of the file, the owning group and the others. Now even the owner tux does not have write access to the file without first reestablishing write permissions.
17.6 Useful Features of the Shell As you probably noticed in the examples above, entering commands in Bash can include a lot of typing. In the following, get to know some features of the Bash that can make your work a lot easier and save a lot of typing. History By default, Bash “remembers” commands you have entered. This feature is called history. You can browse through commands that have been entered before, select one you want to repeat and then execute it again.
Wild Card Function ? Matches exactly one arbitrary character * Matches any number of characters [set] Matches one of the characters from the group specified inside the square brackets, which is represented here by the string set. 17.6.1 Examples For Using History, Completion and Wildcards The following examples illustrate how to make use of these convenient features of Bash. Procedure 17.6 Using History and Completion If you already did the example Section 17.3.
filenames myfile1.txt, myfile2.txt etc. You want to search for certain files according to their properties. 1 First, create some test files in your home directory: 1a Use the touch command to create several (empty) files with different file extensions, for example .pdf, .xml and .jpg. You can do this consecutively (do not forget to use the Bash history function) or with only one touch command: simply add several filenames separated by a space.
Note that you can only use the ? wild card here because the numbering of the files is single-digit. As soon as you have a file named myfile10.txt you must to use the * wild card to view all versions of myfile.txt (or add another question mark, so your string looks like myfile??.txt). 2c To remove, for example, version 1-3 and version 5 of myfile.txt, enter rm myfile[1-3,5].txt 2d Check the result with ls -l Of all myfile.txt versions only myfile4.txt should be left.
extended mode In this mode, also known as colon mode (as you have to enter a colon to switch to this mode), vi can execute also more complex tasks such as searching and replacing text. In the following (very simple) example, you will learn how to open and edit a file with vi, how to save your changes and quit vi. 17.7.1 Example: Editing with vi NOTE: Display of Keys In the following, find several commands that you can enter in vi by just pressing keys. These appear in uppercase as on a keyboard.
If desired, use wild cards to specify filenames. The program is very quick, because it uses a database specifically created for the purpose (rather than searching through the entire file system). This very fact, however, also results in a major drawback: locate is unable to find any files created after the latest update of its database. The database can be generated by root running updatedb. find With find, search for a file in a given directory.
If you want to use a search string which consists of more than one word, enclose the string in double quotation marks, for example: grep "music is great" ~/* 17.9 Viewing Text Files When searching for the contents of a file with grep, the output gives you the line in which the searchstring was found along with the filename. Often this contextual information is still not enough information to decide whether you want to open and edit this file.
Normally, the standard output in the shell is your screen (or an open shell window) and the standard input is the keyboard. With the help of certain symbols you can redirect the input or the output to another object, such as a file or another command. Redirection With > you can forward the output of a command to a file (output redirection), with < you can use a file as input for a command (input redirection).
The pipe is also often used in combination with the grep command in order to search for a certain string in the output of another command. For example, if you want to view a list of files in a directory which are owned by the user tux, enter ls -l | grep tux 17.11 Starting Programs and Handling Processes As you have seen in Section 17.7, “Editing Texts” (page 206), programs can be started from the shell.
In case a program cannot be terminated in the normal way, use the kill command to stop the process (or processes) belonging to that program. To do so, specify the process ID (PID) shown by the output of ps. For example, to shut down the KWrite editor in the example above, enter kill 30187 This sends a TERM signal that instructs the program to shut itself down.
17.12.1 File Commands The following section lists the most important commands for file management. It covers everything from general file administration to the manipulation of file system ACLs. 17.12.1.1 File Administration ls [options] [files] If you run ls without any additional parameters, the program lists the contents of the current directory in short form. -l Detailed list -a Displays hidden files cp [options] source target Copies source to target.
it creates a symbolic link that only points to the directory in which source is located, enabling linking across file systems. -s Creates a symbolic link cd [options] [directory] Changes the current directory. cd without any parameters changes to the user's home directory. mkdir [options] directory Creates a new directory. rmdir [options] directory Deletes the specified directory if it is already empty.
x Execute—executing files or changing to the directory s Setuid bit—the application or program is started as if it were started by the owner of the file As an alternative, a numeric code can be used. The four digits of this code are composed of the sum of the values 4, 2, and 1—the decimal result of a binary mask. The first digit sets the set user ID (SUID) (4), the set group ID (2), and the sticky (1) bits. The second digit defines the permissions of the owner of the file.
-z Packs the resulting archive with gzip -j Compresses the resulting archive with bzip2 -v Lists files processed The archive files created by tar end with .tar. If the tar archive was also compressed using gzip, the ending is .tgz or .tar.gz. If it was compressed using bzip2, the ending is .tar.bz2. locate patterns This command is only available if you have installed the findutils-locate package. The locate command can find in which directory a specified file is located.
less [options] files This command can be used to browse the contents of the specified file. Scroll half a screen page up or down with [PgUp] and [PgDn] or a full screen page down with [Space]. Jump to the beginning or end of a file using [Home] and [End]. Press [Q] to exit the program. grep [options] searchstring files The grep command finds a specific search string in the specified files. If the search string is found, the command displays the line in which searchstring was found along with the filename.
mounted by other users, enter the option user in the appropriate line in the /etc/ fstab file (separated by commas) and save this change. Further information is available in the mount(1) man page. umount [options] mountpoint This command unmounts a mounted drive from the file system. To prevent data loss, run this command before taking a removable data medium from its drive. Normally, only root is allowed to run the commands mount and umount.
-b Output in bytes -k Output in kilobytes -m Output in megabytes date [options] This simple program displays the current system time. If run as root, it can also be used to change the system time. Details about the program are available in the date(1) man page. 17.12.2.2 Processes top [options] top provides a quick overview of the currently running processes. Press [H] to access a page that briefly explains the main options for customizing the program.
-cnumber Determines the total number of packages to send and ends after they have been dispatched (by default, there is no limitation set) -f flood ping: sends as many data packages as possible; a popular means, reserved for root, to test networks -ivalue Specifies the interval between two data packages in seconds (default: one second) host [options] hostname [server] The domain name system resolves domain names to IP addresses. With this tool, send queries to name servers (DNS servers).
17.12.3 For More Information There are many more commands than listed in this chapter. For information about other commands or more detailed information, the O'Reilly publication Linux in a Nutshell is recommended.
18 Bash and Bash Scripts These days many people use computers with a graphical user interface (GUI) like KDE or GNOME. Although they offer lots of features, their use is limited when it comes to the execution of automatical tasks. Shells are a good addition to GUIs and this chapter gives you an overview of some aspects of shells, in this case Bash. 18.1 What is “The Shell”? Traditionally, the shell is Bash (Bourne again Shell). When this chapter speaks about “the shell” it means Bash.
File Description ~/.profile Insert user specific configuration for login shells here Table 18.2 Bash Configuration Files for Non-Login Shells /etc/bash.bashrc Do not modify this file, otherwise your modifications can be destroyed during your next update! /etc/bash.bashrc.local Use this file to insert your system-wide modifications for Bash only ~/.bashrc Insert user specific configuration here Additionally, Bash uses some more files: Table 18.3 Special Files for Bash File Description ~/.
Directory Contents /dev Files needed to access host-specific devices. /etc Host-specific system configuration files. /home Holds the home directories of all users who have accounts on the system. However, root's home directory is not located in /home but in /root. /lib Essential shared libraries and kernel modules. /media Mount points for removable media. /mnt Mount point for temporarily mounting a file system. /opt Add-on application software packages.
/boot Contains data required for booting, such as the boot loader, the kernel, and other data that is used before the kernel begins executing user-mode programs. /dev Holds device files that represent hardware components. /etc Contains local configuration files that control the operation of programs like the X Window System. The /etc/init.d subdirectory contains scripts that are executed during the boot process. /home/username Holds the private data of every user who has an account on the system.
/sbin As the s indicates, this directory holds utilities for the superuser. /sbin contains the binaries essential for booting, restoring and recovering the system in addition to the binaries in /bin. /srv Holds data for services provided by the system, such as FTP and HTTP. /tmp This directory is used by programs that require temporary storage of files. IMPORTANT: Cleaning up /tmp at Boot Time Data stored in /tmp are not guaranteed to survive a system reboot.
/var Whereas /usr holds static, read-only data, /var is for data which is written during system operation and thus is variable data, such as log files or spooling data. For an overview of the most important log files you can find under /var/log/, refer to Table A.2, “Log Files” (page 240). /windows Only available if you have both Microsoft Windows and Linux installed on your system. Contains the Windows data available on the Windows partition of your system.
3. The script needs executable permissions. Set the permissions with the following command: chmod +x ~/bin/hello.sh If you have fullfilled all of the above prerequisites, you can execute the script in the following ways: 1. As Absolute Path The script can be executed with an absolute path. In our case, it is ~/bin/hello.sh. 2. Everywhere If the PATH environment variable contains the directory where the script is located, you can execute the script just with hello.sh. 18.
cat /proc/cpuinfo | grep cpu Every channel has a file descriptor: 0 (zero) for standard input, 1 for standard output and 2 for standard error. It is allowed to insert this file descriptor before a < or > character. For example, the following line searches for a file starting with foo, but suppresses its errors by redirecting it to /dev/null: find / -name "foo*" 2>/dev/null 18.4 Using Aliases An alias is a shortcut definition of one or more commands.
unset NAME The following table contains some common environment variables which can be used in you shell scripts: Table 18.5 Useful Environment Variables HOME the home directory of the current user HOST the current host name LANG when a tool is localized, it uses the language from this environment variable.
18.5.2 Using Variable Substitution Variable substitutions apply a pattern to the content of a variable either from the left or right side. The following list contains the possible syntax forms: ${VAR#pattern} removes the shortest possible match from the left: file=/home/tux/book/book.tar.bz2 echo ${file#*/} home/tux/book/book.tar.bz2 ${VAR##pattern} removes the longest possible match from the left: file=/home/tux/book/book.tar.bz2 echo ${file##*/} book.tar.
Command1 ; Command2 executes the commands in sequential order. The exit code is not checked. The following line displays the content of the file with cat and then prints its file properties with ls regardless of their exit codes: cat filelist.txt ; ls -l filelist.txt Command1 && Command2 runs the right command, if the left command was successful (logical AND).
The test expression can be as complex or simple as possible. The following expression checks if the file foo.txt exists: if test -e /tmp/foo.txt ; then echo "Found foo.txt" fi The test expression can also be abbreviated in angled brackets: if [ -e /tmp/foo.txt ] ; then echo "Found foo.txt" fi Find more useful expressions at http://www.cyberciti.biz/nixcraft/linux/docs/ uniqlinuxfeatures/lsst/ch03sec02.html. 18.7.
A Help and Troubleshooting A.1 Help and Documentation openSUSE® comes with various sources of information and documentation, many of which are already integrated into your installed system. Documentation in /usr/share/doc This traditional help directory holds various documentation files and release notes for your system. It contains also information of installed packages in the subdirectory packages. Find more detailed information in Section A.1.1, “Documentation Directory” (page 235).
find in /usr/share/docs also depends on the (documentation) packages installed. If you cannot find the subdirectories mentioned here, check if the respective packages are installed on your system and add them with YaST, if needed. A.1.1.1 Novell/SUSE Manuals We provide HTML and PDF versions of our books in different languages. In the manual subdirectory, find HTML versions of most of the Novell/SUSE manuals available for your product.
INSTALL How to install this package on your system. As the package is already installed by the time you get to read this file, you can safely ignore the contents of this file. README, README.* General information on the software. For example, for what purpose and how to use it. TODO Things that are not implemented yet, but probably will be in the future. MANIFEST List of files with a brief summary. NEWS Description of what is new in this version. A.1.
Number Description 7 Miscellaneous (including macro packages and conventions), for example, man(7), groff(7) 8 System administration commands (usually only for root) 9 Kernel routines (nonstandard) Each man page consists of several parts labeled NAME , SYNOPSIS , DESCRIPTION , SEE ALSO , LICENSING , and AUTHOR . There may be additional sections available depending on the type of command. A.1.3 Info Pages Info pages are another important source of information on your system.
openSUSE Forums There are several openSUSE forums where you can dive in on discussions about openSUSE, or get support. See http://en.opensuse.org/openSUSE:Forums_list for a list. KDE Documentation Find documentation for many aspects of KDE suitable for users and administrators at http://www.kde.org/documentation/. GNOME Documentation Documentation for GNOME users, administrators and developers is available at http://library.gnome.org/.
Table A.2 Log Files Log File Description ~/.xsession-errors Messages from the desktop applications currently running. /var/log/apparmor/ Log files from AppArmor, see Part “Confining Privileges with AppArmor” (↑Security Guide) for detailed information. /var/log/boot.msg Messages from the kernel reported during the boot process. /var/log/mail.* Messages from the mail system. /var/log/messages Ongoing messages from the kernel and system log daemon (when running).
Apart from log files, your machine also supplies you with information about the running system. See Table A.3: System Information With the /proc File System Table A.3 System Information With the /proc File System File Description /proc/cpuinfo Contains processor information, including its type, make, model, and performance. /proc/dma Shows which DMA channels are currently being used. /proc/interrupts Shows which interrupts are in use, and how many of each have been in use.
File Description /sys/bus Contains subdirectories for each physical bus type. /sys/class Contains subdirectories grouped together as a functional types of devices (like graphics, net, printer, etc.) /sys/device Contains the global device hierarchy. Linux comes with a number of tools for system analysis and monitoring. See Chapter 2, System Monitoring Utilities (↑System Analysis and Tuning Guide) for a selection of the most important ones used in system diagnostics.
Using an External Boot Device If it is supported by your BIOS and the installation kernel, boot from external DVD drives or USB storage devices. Network Boot via PXE If a machine lacks a DVD drive, but provides a working ethernet connection, perform a completely network-based installation.
3 In the screen that opens, look for a subentry called BOOT SEQUENCE or BOOT ORDER. The boot sequence looks something like C,A or A,C. In the former case, the machine first searches the hard disk (C) then the floppy drive (A) to find a bootable medium. Change the settings by pressing [PgUp] or [PgDown] until the sequence is A,CDROM,C. 4 Leave the BIOS setup screen by pressing [Esc]. To save the changes, select SAVE & EXIT SETUP, or press [F10]. To confirm that your settings should be saved, press [Y].
installation kernel, or due to certain functionality included in this kernel, such as ACPI, that can still cause problems on some hardware. If your system fails to install using the standard Installation mode from the first installation boot screen, try the following: 1 With the DVD still in the drive, reboot the machine with [Ctrl] + [Alt] + [Del] or using the hardware reset button.
pci=noacpi Disable PCI IRQ routing of the new ACPI system. pnpacpi=off This option is for serial or parallel problems when your BIOS setup contains wrong interrupts or ports. notsc Disable the time stamp counter. This option can be used to work around timing problems on your systems. It is a recent feature, if you see regressions on your machine, especially time related or even total hangs, this option is worth a try. nohz=off Disable the nohz feature. If your machine hangs, this option may help.
2 Press [F3] and select Text Mode. 3 Select Installation and proceed with the installation as described in Chapter 1, Installation with YaST (↑Reference). Procedure A.5 VNC Installation 1 Boot for installation. 2 Enter the following text at the boot options prompt: vnc=1 vncpassword=some_password Replace some_password with the password to use for VNC installation. 3 Select Installation then press [Enter] to start the installation .
Boot Options Unlike the graphical interface, the different boot options cannot be selected using the cursor keys of your keyboard. The boot menu of the text mode boot screen offers some keywords to enter at the boot prompt. These keywords map to the options offered in the graphical version. Enter your choice and hit [Enter] to launch the boot process.
The returned line indicates that the machine's default runlevel (initdefault) is set to 5 and that it should boot to the graphical desktop. If the runlevel is set to any other number, use the YaST Runlevel Editor module to set it to 5. IMPORTANT Do not edit the runlevel configuration manually. Otherwise SuSEconfig (run by YaST) will overwrite these changes on its next run. If you need to make manual changes here, disable future SuSEconfig changes by setting CHECK_INITTAB in /etc/sysconfig/suseconfig to no.
• If the system is configured to use Kerberos, the system's local time may have drifted past the accepted variance with the Kerberos server time (this is typically 300 seconds). If NTP (network time protocol) is not working properly or local NTP servers are not working, Kerberos authentication ceases to function because it depends on common clock synchronization across the network. • The system's authentication configuration is misconfigured.
his password correctly, use the YaST User Management module to change the user's password. Pay attention to the [Caps Lock] key and unlock it, if necessary. 2 Log in as root and check /var/log/messages for error messages of the login process and of PAM. 3 Try to log in from a console (using [Ctrl] + [Alt] + [F1]). If this is successful, the blame cannot be put on PAM, because it is possible to authenticate this user on this machine.
• The machine cannot reach the authentication server or directory server that contains that user's information. • There may be problems with the X Window System authenticating this particular user, especially if the user's home has been used with another Linux distribution prior to installing the current one.
A.2.4.3 Login to Encrypted Home Partition Fails It is recommended to use an encrypted home partition for laptops. If you cannot log in to your laptop, the reason is usually simple: your partition could not be unlocked. During the boot time, you have to enter the passphrase to unlock your encrypted partition. If you do not enter it, the boot process continues, leaving the partition locked. To unlock your encrypted partition, proceed as follows: 1 Switch to the text console with [Ctrl] + [Alt] + [F1].
6 Recover your individual application configuration data (including the Evolution e-mail client data) by copying the ~/.gconf-ORIG-RECOVER/apps/ directory back into the new ~/.gconf directory as follows: cp -a .gconf-ORIG-RECOVER/apps .gconf/ If this causes the login problems, attempt to recover only the critical application data and reconfigure the remainder of the applications. A.2.4.5 Login Successful but KDE Desktop Fails There are several reasons why a KDE desktop would not allow users to login.
4 Log out. 5 Log in again. 6 After the desktop has started successfully, copy the user's own configurations back into place: cp -a KDEDIR/share .kde/share Replace KDEDIR with the directory from Step 3 (page 254). IMPORTANT If the user's own adjustments caused the login to fail and continue to do so, repeat the procedure as described above, but do not copy the .kde/ share directory. A.2.5 Network Problems Many problems of your system may be network-related, even though they do not seem to be at first.
issues, users would not even be able to log in. Machines in the network managed by a broken name server would not be able to “see” each other and communicate. NTP (Time Service) A malfunctioning or completely broken NTP service could affect Kerberos authentication and X server functionality. NFS (File Service) If any application needs data stored in an NFS mounted directory, it will not be able to start or function properly if this service was down or misconfigured.
If ping fails with destination host unreachable, either your system or the desired server is not properly configured or down. Check whether your system is reachable by running ping IP address or your_hostname from another machine. If you can reach your machine from another machine, it is the server that is not running at all or not configured correctly. If ping fails with unknown host, the name service is not configured correctly or the hostname used was incorrect.
The dns entry is vital. It tells Linux to use an external name server. Normally, these entries are automatically managed by YaST, but it would be prudent to check. If all the relevant entries on the host are correct, let your system administrator check the DNS server configuration for the correct zone information. For detailed information about DNS, refer to Chapter 11, The Domain Name System (↑Reference).
3 Open a web page, for example, http://www.opensuse.org as normal user to see, if you can connect. 4 Collect any information about the state of NetworkManager in /var/log/ NetworkManager. For more information about NetworkManager, refer to Chapter 21, Using NetworkManager (↑Reference). A.2.6 Data Problems Data problems are when the machine may or may not boot properly but, in either case, it is clear that there is data corruption on the system and that the system needs to be recovered.
1 As root, start YaST and select System > System Backup. 2 Create a backup profile holding all details needed for the backup, filename of the archive file, scope, and type of the backup: 2a Select Profile Management > Add. 2b Enter a name for the archive. 2c Enter the path to the location of the backup if you want to keep a local backup. For your backup to be archived on a network server (via NFS), enter the IP address or name of the server and the directory that should hold your archive.
6 Click OK to apply your settings and have the first backup start at the time specified. A.2.6.3 Restoring a System Backup Use the YaST System Restoration module to restore the system configuration from a backup. Restore the entire backup or select specific components that were corrupted and need to be reset to their old state. 1 Start YaST > System > System Restoration. 2 Enter the location of the backup file.
• Recover from a badly installed device driver or unusable kernel. • Resize partitions using the parted command. Find more information about this tool at the GNU Parted website http://www.gnu.org/software/parted/parted .html. The rescue system can be loaded from various sources and locations. The simplest option is to boot the rescue system from the original installation medium: 1 Insert the installation medium into your DVD drive. 2 Reboot the system. 3 At the boot screen, press [F4] and choose DVD-ROM.
Checking and Manipulating Configuration Files As an example for a configuration that might be fixed using the rescue system, imagine you have a broken configuration file that prevents the system from booting properly. You can fix this using the rescue system. To manipulate a configuration file, proceed as follows: 1 Start the rescue system using one of the methods described above.
mount /dev/sda6 /mnt mount --bind /dev /mnt/dev 2 Now you can “change root” into the new environment: chroot /mnt 3 Then mount /proc and /sys: mount /proc mount /sys 4 Finally, mount the remaining partitions from the installed system: mount -a 5 Now you have access to the installed system. Before rebooting the system, unmount the partitions with umount -a and leave the “change root” environment with exit.
1 Perform the necessary steps to access the installed system as described in Section “Accessing the Installed System” (page 263). 2 Check whether the following files are correctly configured according to the GRUB configuration principles outlined in Chapter 6, The Boot Loader GRUB (↑Reference) and apply fixes if necessary. • /etc/grub.conf • /boot/grub/device.map • /boot/grub/menu.lst • /etc/sysconfig/bootloader 3 Reinstall the boot loader using the following command sequence: grub --batch < /etc/grub.
nized by the operating system. The vendor typically releases a Driver Update Disk with the fixed or updated version of the required driver. In both cases you need to access the installed system in the rescue mode and fix the kernel related problem, otherwise the system may fail to boot correctly: 1 Boot from the openSUSE installation media. 2 If you are recovering after a faulty kernel update, skip this step.
A.3 Legal Notice Copyright© 2006– 2011 Novell, Inc. and contributors. All rights reserved. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or (at your option) version 1.3; with the Invariant Section being this copyright notice and license. A copy of the license version 1.2 is included in the section entitled “GNU Free Documentation License”.
arranged to thwart or discourage subsequent modification by readers is not Transparent. An image format is not Transparent if used for any substantial amount of text. A copy that is not “Transparent” is called “Opaque”. Examples of suitable formats for Transparent copies include plain ASCII without markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly available DTD, and standard-conforming simple HTML, PostScript or PDF designed for human modification.
K. For any section Entitled “Acknowledgements” or “Dedications”, Preserve the Title of the section, and preserve in the section all the substance and tone of each of the contributor acknowledgements and/or dedications given therein. L. Preserve all the Invariant Sections of the Document, unaltered in their text and in their titles. Section numbers or the equivalent are not considered part of the section titles. M. Delete any section Entitled “Endorsements”.
ADDENDUM: How to use this License for your documents To use this License in a document you have written, include a copy of the License in the document and put the following copyright and license notices just after the title page: Copyright (c) YEAR YOUR NAME. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.