Index: head/zh_TW.UTF-8/books/handbook/linuxemu/chapter.xml =================================================================== --- head/zh_TW.UTF-8/books/handbook/linuxemu/chapter.xml +++ head/zh_TW.UTF-8/books/handbook/linuxemu/chapter.xml @@ -6,65 +6,73 @@ Original revision: 1.132 --> - 與 Linux Binary 的相容方面 + + &linux; 二進位檔的相容性 + - JimMockRestructured and parts updated by + + + Jim + Mock + + Restructured and parts updated by + + - Brian N.HandyOriginally contributed by - RichMurphey + + + Brian N. + Handy + + Originally contributed by + + + + + Rich + Murphey + + - - 概述 - Linux binary compatibility + + + Linux binary compatibility + binary compatibility Linux - FreeBSD 有提供其他幾種 &unix; like 作業系統的 binary 相容性,其中包括了 Linux。 - 你可能會納悶:為什麼 FreeBSD 需要能夠執行 Linux 專用執行檔(binary)呢?答案很簡單, - 許多公司、開發者只會 Linux 開發程式,因為這是目前資訊界 最熱門 的玩意。 - 這逼得許多 FreeBSD 使用者不得不去勸說這些人是否提供可直接在 FreeBSD 上執行的版本。 - 但問題是,大多數公司並不瞭解會有多少人會用 FreeBSD 版,因此他們仍只開發 Linux 版。 - 那麼 FreeBSD 使用者該怎麼辦呢?答案就是用 FreeBSD 所提供的 Linux binary 相容。 - - 簡單來講,這種相容性可讓 FreeBSD 使用者直接執行約 90% 的 Linux 程式,而不必做任何修改。 - 這些包括了: &staroffice;、 - &netscape; 的 Linux 版、 - &adobe; &acrobat;、 - RealPlayer、 - VMware、 - &oracle;、 - WordPerfectDoom、 - Quake 等等。此外,也有人回報說在某些情況下, - 這些在 FreeBSD 上執行的 Linux 程式,甚至比原本在 Linux 執行得更好。 - - 然而呢,還是有些只限 Linux 特定的作業系統功能,在 FreeBSD 上並未支援。 - 如果 Linux 程式過於濫用只有 &i386; 架構上才能用的功能,比如:虛擬 8086 模式, - 則可能無法在 FreeBSD 運作正常。 + &os; 提供和32位元 &linux; 二進位檔的相容性,允許使用者在 &os;不需要修改就可以安裝和執行大部份32位元 &linux; 二進位檔。 + 曾經有人指出,在某些情況下,32位元 &linux;二進位檔在 &os; 的表現比在 &linux;好。 + + 然而,某些However, some &linux;作業系統的特色在 &os; 並未支援。 + 例如,如果 &linux; 二進位檔過度使用&i386;特定的呼叫,像是啟動虛擬8086模式,將無法在 &os; 執行。此外,64位元 &linux; 二進位檔目前也尚未支援。 + + 讀完本章後,您將了解: - 讀完這章,您將了解: - 如何啟用 Linux 相容模式。 + 如何在&os;系統啟用 &linux; 相容模式 &os;。 - 如何安裝額外的 Linux share libraries。 - + 如何安裝額外的 &linux; 共享程式庫。 + - 如何在 FreeBSD 上安裝 Linux 程式。 + 如何在&os;系統安裝 &linux; 應用程式。 - FreeBSD 上的 Linux 相容模式的實作細節。 + The implementation details of &linux; compatibility in + &os;. @@ -72,466 +80,375 @@ - 知道如何透過 port 機制來安裝軟體()。 + 知道如何安裝 額外的第3方軟體。 - 安裝 + 設置 &linux; 二進位檔相容性 - KLD (kernel loadable object) + Ports Collection - 預設並不會打開 Linux 相容模式,最簡單的啟用方式,就是載入 - linux KLD object (Kernel LoaDable - object)。 載入方式,請切為 root - 權限,然後打下列指令: + &linux; 程式庫並未預設安裝,而且 &linux; 二進位檔相容性並未啟用。 + &linux; 程式庫可以手動安裝或是從 &os; Ports 安裝。 + + 編譯 port 前,要載入 &linux; 核心模組,否則編譯會失敗: &prompt.root; kldload linux - 若要每次開機都啟用的話,請把下列內容加到 - /etc/rc.conf 檔: + 確認模組已載入: - linux_enable="YES" + &prompt.user; kldstat + Id Refs Address Size Name + 1 2 0xc0100000 16bdb8 kernel + 7 1 0xc24db000 d000 linux.ko - 另外可以用 &man.kldstat.8; 指令,來確認有哪些 KLD 有載入: + 在 &os; 安裝基本的 &linux; 程式庫和二進位檔最簡單的方式是安裝 emulators/linux_base-c6 套件或是 port 。安裝 port: + + &prompt.root; printf "compat.linux.osrelease=2.6.18\n" >> /etc/sysctl.conf +&prompt.root; sysctl compat.linux.osrelease=2.6.18 +&prompt.root; pkg install emulators/linux_base-c6 + + 要讓 &linux; 相容性在開機時就啟用,可以加入這行到 /etc/rc.conf: + + linux_enable="YES" - &prompt.user; kldstat -Id Refs Address Size Name - 1 2 0xc0100000 16bdb8 kernel - 7 1 0xc24db000 d000 linux.ko kernel options COMPAT_LINUX - If for some reason you do not want to or cannot load the KLD, - then you may statically link Linux binary compatibility into the kernel - by adding options COMPAT_LINUX to your kernel - configuration file. Then install your new kernel as described in - . + 想要靜態連結 &linux; 二進位檔相容性到自訂核心的使用者應該增加 options COMPAT_LINUX 到他們自訂核心設定檔。 + 編譯和安裝新核心的方法,如 所述。 + + + 手動安裝額外的程式庫 - - Installing Linux Runtime Libraries - Linux - installing Linux libraries + shared libraries - This can be done one of two ways, either by using the - linux_base port, or - by installing them manually. - - - Installing Using the linux_base Port - Ports Collection - - This is by far the easiest method to use when installing the - runtime libraries. It is just like installing any other port - from the Ports Collection. - Simply do the following: - - &prompt.root; cd /usr/ports/emulators/linux_base-fc4 -&prompt.root; make install distclean - - You should now have working Linux binary compatibility. - Some programs may complain about incorrect minor versions of the - system libraries. In general, however, this does not seem to be - a problem. - - There may be multiple versions of the emulators/linux_base port available, - corresponding to different versions of various Linux distributions. - You should install the port most closely resembling the - requirements of the Linux applications you would like to - install. - - - - - Installing Libraries Manually + 如果一個 &linux; 應用程式在設定 &linux;二進位檔相容性後表示缺少共享程式庫, + 看看這個&linux; 二進位檔需要哪個共享程式庫,手動安裝他。 - If you do not have the ports collection - installed, you can install the libraries by hand instead. You - will need the Linux shared libraries that the program depends on - and the runtime linker. Also, you will need to create a - shadow root directory, - /compat/linux, for Linux libraries on your - FreeBSD system. Any shared libraries opened by Linux programs - run under FreeBSD will look in this tree first. So, if a Linux - program loads, for example, /lib/libc.so, - FreeBSD will first try to open - /compat/linux/lib/libc.so, and if that does - not exist, it will then try /lib/libc.so. - Shared libraries should be installed in the shadow tree - /compat/linux/lib rather than the paths - that the Linux ld.so reports. - - Generally, you will need to look for the shared libraries - that Linux binaries depend on only the first few times that you - install a Linux program on your FreeBSD system. After a while, - you will have a sufficient set of Linux shared libraries on your - system to be able to run newly imported Linux binaries without - any extra work. - - - - How to Install Additional Shared Libraries - shared libraries - - What if you install the linux_base port - and your application still complains about missing shared - libraries? How do you know which shared libraries Linux - binaries need, and where to get them? Basically, there are 2 - possibilities (when following these instructions you will need - to be root on your FreeBSD system). - - If you have access to a Linux system, see what shared - libraries the application needs, and copy them to your FreeBSD - system. Look at the following example: - - - Let us assume you used FTP to get the Linux binary of - Doom, and put it on a Linux system you have access to. You - then can check which shared libraries it needs by running - ldd linuxdoom, like so: + &linux; 系統中, ldd 可以用來決定應用程式需要哪個。 + 例如,檢查 linuxdoom 需要哪個共享程式庫,從安裝 Doom的 &linux; 系統中執行這個指令: - &prompt.user; ldd linuxdoom + &prompt.user; ldd linuxdoom libXt.so.3 (DLL Jump 3.1) => /usr/X11/lib/libXt.so.3.1.0 libX11.so.3 (DLL Jump 3.1) => /usr/X11/lib/libX11.so.3.1.0 libc.so.4 (DLL Jump 4.5pl26) => /lib/libc.so.4.6.29 - symbolic links - You would need to get all the files from the last column, - and put them under /compat/linux, with - the names in the first column as symbolic links pointing to - them. This means you eventually have these files on your - FreeBSD system: + + symbolic links + + + 然後,複製所有 &linux; 系統輸出最後一欄的檔案到 &os;系統的 /compat/linux 。 + 複製完後,建立符號連結到剛剛輸出第一欄的名字。這個例子會在 &os; 系統產生以下檔案: - /compat/linux/usr/X11/lib/libXt.so.3.1.0 + /compat/linux/usr/X11/lib/libXt.so.3.1.0 /compat/linux/usr/X11/lib/libXt.so.3 -> libXt.so.3.1.0 /compat/linux/usr/X11/lib/libX11.so.3.1.0 /compat/linux/usr/X11/lib/libX11.so.3 -> libX11.so.3.1.0 /compat/linux/lib/libc.so.4.6.29 /compat/linux/lib/libc.so.4 -> libc.so.4.6.29 -
- - Note that if you already have a Linux shared library - with a matching major revision number to the first column - of the ldd output, you will not need to - copy the file named in the last column to your system, the - one you already have should work. It is advisable to copy - the shared library anyway if it is a newer version, - though. You can remove the old one, as long as you make - the symbolic link point to the new one. So, if you have - these libraries on your system: + If a &linux; shared library already exists with a + matching major revision number to the first column of the + ldd output, it does not need to be copied + to the file named in the last column, as the existing library + should work. It is advisable to copy the shared library if it + is a newer version, though. The old one can be removed, as + long as the symbolic link points to the new one. + + For example, these libraries already exist on the &os; + system: - /compat/linux/lib/libc.so.4.6.27 + /compat/linux/lib/libc.so.4.6.27 /compat/linux/lib/libc.so.4 -> libc.so.4.6.27 - and you find a new binary that claims to require a - later version according to the output of - ldd: - - libc.so.4 (DLL Jump 4.5pl26) -> libc.so.4.6.29 - - If it is only one or two versions out of date in the - in the trailing digit then do not worry about copying - /lib/libc.so.4.6.29 too, because the - program should work fine with the slightly older version. - However, if you like, you can decide to replace the - libc.so anyway, and that should leave - you with: + and ldd indicates that a binary + requires a later version: + + libc.so.4 (DLL Jump 4.5pl26) -> libc.so.4.6.29 + + Since the existing library is only one or two versions out + of date in the last digit, the program should still work with + the slightly older version. However, it is safe to replace + the existing libc.so with the newer + version: - /compat/linux/lib/libc.so.4.6.29 + /compat/linux/lib/libc.so.4.6.29 /compat/linux/lib/libc.so.4 -> libc.so.4.6.29 - -
-
- - The symbolic link mechanism is - only needed for Linux binaries. The - FreeBSD runtime linker takes care of looking for matching - major revision numbers itself and you do not need to worry - about it. - -
-
-
+ Generally, one will need to look for the shared libraries + that &linux; binaries depend on only the first few times that + a &linux; program is installed on &os;. After a while, there + will be a sufficient set of &linux; shared libraries on the + system to be able to run newly installed &linux; binaries + without any extra work.
- Installing Linux ELF Binaries + 安裝 &linux; <acronym>ELF</acronym> + 二進位檔 + Linux ELF binaries - ELF binaries sometimes require an extra step of - branding. If you attempt to run an unbranded ELF - binary, you will get an error message like the following: + ELF 二進位等有時候需要額外的步驟。當執行未標記的 ELF 二進位檔,會產生錯誤訊息: &prompt.user; ./my-linux-elf-binary ELF binary type not known Abort - To help the FreeBSD kernel distinguish between a FreeBSD ELF - binary from a Linux binary, use the &man.brandelf.1; - utility. + 為了幫 &os; 核心辨識 &os; ELF 二進位檔和 &linux; 二進位檔,使用 &man.brandelf.1;: &prompt.user; brandelf -t Linux my-linux-elf-binary - GNU toolchain - The GNU toolchain now places the appropriate branding - information into ELF binaries automatically, so this step - should become increasingly unnecessary in the future. + + GNU toolchain + + + 因為GNU工具鏈會自動放置適當的標記資訊進 ELF 二進位檔,通常就不需要這個步驟。 + + + + 安裝 &linux; <acronym>RPM</acronym> 基礎的應用程式 + + 要安裝 &linux; RPM 基礎的應用程式,先安裝 archivers/rpm 套件或 port。 + 安裝後, root 可以使用這個指令來安裝.rpm檔: + + &prompt.root; cd /compat/linux +&prompt.root; rpm2cpio < /path/to/linux.archive.rpm | cpio -id + + 如果需要, brandelf 已安裝的 ELF二進位檔。注意,這將會無法乾淨地解除安裝。 - Configuring the Hostname Resolver + 設定主機名稱解析器(Hostname Resolver) - If DNS does not work or you get this message: + 如果 DNS 有問題或是出現這個錯誤: resolv+: "bind" is an invalid keyword resolv+: "hosts" is an invalid keyword - You will need to configure a - /compat/linux/etc/host.conf file - containing: + /compat/linux/etc/host.conf設定如下: order hosts, bind multi on - The order here specifies that /etc/hosts - is searched first and DNS is searched second. When - /compat/linux/etc/host.conf is not - installed, Linux applications find FreeBSD's - /etc/host.conf and complain about the - incompatible FreeBSD syntax. You should remove - bind if you have not configured a name server - using the /etc/resolv.conf file. + 這指定先搜尋 /etc/hostsDNS 次之。 + 當 /compat/linux/etc/host.conf 不存在, &linux; 應用程式會使用 /etc/host.conf 並會抱怨不相容的 &os; 語法。 + 如果名稱伺服器未設定使用/etc/resolv.conf的話,移除 bind
- - Installing &mathematica; + + - BorisHollasUpdated for Mathematica 5.X by + + Boris + Hollas + Updated for Mathematica 5.X by + - - + + + Installing &mathematica; applications Mathematica - This document describes the process of installing the Linux - version of &mathematica; 5.X onto - a FreeBSD system. - - The Linux version of &mathematica; - or &mathematica; for Students can - be ordered directly from Wolfram at - http://www.wolfram.com/. + This section describes the process of installing the &linux; + version of &mathematica; 9.X onto a + &os; system. &mathematica; is a + commercial, computational software program used in scientific, + engineering, and mathematical fields. A 30 day trial version is + available for download from wolfram.com/mathematica. Running the &mathematica; Installer - First, you have to tell &os; that - &mathematica;'s Linux - binaries use the Linux ABI. The easiest way to do so is to - set the default ELF brand - to Linux for all unbranded binaries with the command: + Before installing &mathematica;, make sure that the + textproc/linux-c6-aspell + package or port is installed and that the &man.linprocfs.5; + file system is mounted. &prompt.root; sysctl kern.fallback_elf_brand=3 - This will make &os; assume that unbranded ELF binaries - use the Linux ABI and so you should be able to run the - installer straight from the CDROM. - - Now, copy the file MathInstaller to - your hard drive: - - &prompt.root; mount /cdrom -&prompt.root; cp /cdrom/Unix/Installers/Linux/MathInstaller /localdir/ - - and in this file, replace /bin/sh in - the first line by /compat/linux/bin/sh. - This makes sure that the installer is executed by the Linux - version of &man.sh.1;. Next, replace all occurrences of - Linux) by FreeBSD) with - a text editor or the script below in the next section. This - tells the &mathematica; installer, - who calls uname -s to determine the - operating system, to treat &os; as a Linux-like operating - system. Invoking MathInstaller will now - install &mathematica;. - - - - Modifying the &mathematica; Executables - - The shell scripts that - &mathematica; created during - installation have to be modified before you can use them. If - you chose /usr/local/bin - as the directory to place the - &mathematica; executables in, you - will find symlinks in this directory to files called - math, mathematica, - Mathematica, and - MathKernel. In each of these, replace - Linux) by FreeBSD) with - a text editor or the following shell script: - - #!/bin/sh -cd /usr/local/bin -for i in math mathematica Mathematica MathKernel - do sed 's/Linux)/FreeBSD)/g' $i > $i.tmp - sed 's/\/bin\/sh/\/compat\/linux\/bin\/sh/g' $i.tmp > $i - rm $i.tmp - chmod a+x $i -done - - - - Obtaining Your &mathematica; Password - - - Ethernet - MAC address - - - When you start &mathematica; - for the first time, you will be asked for a password. If you - have not yet obtained a password from Wolfram, run the program - mathinfo in the installation directory to - obtain your machine ID. This machine ID is - based solely on the MAC address of your first Ethernet card, - so you cannot run your copy of - &mathematica; on different - machines. - - When you register with Wolfram, either by email, phone or fax, - you will give them the machine ID and they will - respond with a corresponding password consisting of groups of - numbers. + &os; will now assume that unbranded ELF binaries use the + &linux; ABI which should allow the + installer to execute from the CDROM. + + The downloaded file will be saved to + /tmp/Mathematica_9.0.1_LINUX.sh. Become + the superuser and run this installer file: + + &prompt.root; sh /tmp/Mathematica_9.0.1_LINUX.sh +Mathematica Secured 9.0.1 for LINUX Installer Archive + +Verifying archive integrity. +Extracting installer. ... + Wolfram Mathematica 9 Installer +Copyright (c) 1988-2013 Wolfram Research, Inc. All rights reserved. + +WARNING: Wolfram Mathematica is protected by copyright law and international treaties. Unauthorized +reproduction or distribution may result in severe civil and criminal +penalties and will be prosecuted to the maximum extent possible under law. + +Enter the installation directory, or press ENTER to select /usr/local/Wolfram/Mathematica/9.0: +> +Now installing... +*********************** +Installation complete. Running the &mathematica; Frontend over a Network &mathematica; uses some special - fonts to display characters not - present in any of the standard font sets (integrals, sums, Greek - letters, etc.). The X protocol requires these fonts to be install - locally. This means you will have to copy - these fonts from the CDROM or from a host with - &mathematica; - installed to your local machine. These fonts are normally stored - in /cdrom/Unix/Files/SystemFiles/Fonts on the - CDROM, or - /usr/local/mathematica/SystemFiles/Fonts on - your hard drive. The actual fonts are in the subdirectories - Type1 and X. There are - several ways to use them, as described below. - - The first way is to copy them into one of the existing font - directories in /usr/X11R6/lib/X11/fonts. - This will require editing the fonts.dir file, - adding the font names to it, and changing the number of fonts on - the first line. Alternatively, you should also just be able to - run &man.mkfontdir.1; in the directory you have copied - them to. + fonts to display characters not present in any of the standard + font sets. Xorg requires these + fonts to be installed locally. This means that these fonts + need to be copied from the CDROM or from a host with + &mathematica; installed to the + local machine. These fonts are normally stored in /cdrom/Unix/Files/SystemFiles/Fonts + on the CDROM, or /usr/local/mathematica/SystemFiles/Fonts + on the hard drive. The actual fonts are in the subdirectories + Type1 and + X. There are several + ways to use them, as described below. + + The first way is to copy the fonts into one of the + existing font directories in /usr/local/lib/X11/fonts then + running &man.mkfontdir.1; within the directory containing the + new fonts. The second way to do this is to copy the directories to - /usr/X11R6/lib/X11/fonts: + /usr/local/lib/X11/fonts: - &prompt.root; cd /usr/X11R6/lib/X11/fonts + &prompt.root; cd /usr/local/lib/X11/fonts &prompt.root; mkdir X &prompt.root; mkdir MathType1 &prompt.root; cd /cdrom/Unix/Files/SystemFiles/Fonts -&prompt.root; cp X/* /usr/X11R6/lib/X11/fonts/X -&prompt.root; cp Type1/* /usr/X11R6/lib/X11/fonts/MathType1 -&prompt.root; cd /usr/X11R6/lib/X11/fonts/X +&prompt.root; cp X/* /usr/local/lib/X11/fonts/X +&prompt.root; cp Type1/* /usr/local/lib/X11/fonts/MathType1 +&prompt.root; cd /usr/local/lib/X11/fonts/X &prompt.root; mkfontdir &prompt.root; cd ../MathType1 &prompt.root; mkfontdir - Now add the new font directories to your font path: + Now add the new font directories to the font path: - &prompt.root; xset fp+ /usr/X11R6/lib/X11/fonts/X -&prompt.root; xset fp+ /usr/X11R6/lib/X11/fonts/MathType1 + &prompt.root; xset fp+ /usr/local/lib/X11/fonts/X +&prompt.root; xset fp+ /usr/local/lib/X11/fonts/MathType1 &prompt.root; xset fp rehash - If you are using the &xorg; server, you can have these font - directories loaded automatically by adding them to your - xorg.conf file. + When using the &xorg; server, + these font directories can be loaded automatically by adding + them to /etc/X11/xorg.conf. - For &xfree86; servers, - the configuration file is XF86Config. fonts - If you do not already have a directory - called /usr/X11R6/lib/X11/fonts/Type1, you - can change the name of the MathType1 - directory in the example above to - Type1. + If /usr/local/lib/X11/fonts/Type1 + does not already exist, change the name of the MathType1 directory in the + example above to Type1. + --> - - Installing &maple; + + + + Dan + Pelleg + Contributed by + - - + + + Installing &matlab; applications MATLAB - This document describes the process of installing the Linux - version of &matlab; version 6.5 onto - a &os; system. It works quite well, with the exception of the - &java.virtual.machine; (see - ). - - The Linux version of &matlab; can be - ordered directly from The MathWorks at http://www.mathworks.com. Make sure you also get - the license file or instructions how to create it. While you - are there, let them know you would like a native &os; - version of their software. + This document describes the process of installing the + &linux; version of + &matlab; version 6.5 onto a &os; + system. It works quite well, with the exception of the + &java.virtual.machine; which is + described further in . + + The &linux; version of &matlab; + can be purchased and licensed from + MathWorks. Consider letting the company know that + you would like a native &os; version of this software. Installing &matlab; - To install &matlab;, do the - following: + To install &matlab;: - Insert the installation CD and mount it. - Become root, as recommended by the - installation script. To start the installation script - type: + Become root, as recommended by + the installation script. Insert the installation CD and + mount it. To start the installation script type: &prompt.root; /compat/linux/bin/sh /cdrom/install - The installer is graphical. If you get errors about - not being able to open a display, type - setenv HOME ~USER, - where USER is the user you did a - &man.su.1; as. + The installer is graphical. If it is not able to + open a display, type setenv HOME + ~USER, + where USER is the user who + ran &man.su.1;. - When asked for the &matlab; root - directory, type: + When asked for the &matlab; + root directory, type: /compat/linux/usr/local/matlab. For easier typing on the rest of the installation - process, type this at your shell prompt: - set MATLAB=/compat/linux/usr/local/matlab + process, type this at the shell prompt: set + MATLAB=/compat/linux/usr/local/matlab. - Edit the license file as instructed when - obtaining the &matlab; license. + Edit the license file as instructed when obtaining + the &matlab; license. - You can prepare this file in advance using your - favorite editor, and copy it to + This file can be prepared in advance using an + editor, and copied to $MATLAB/license.dat before the - installer asks you to edit it. + installer asks to edit it. @@ -709,28 +642,30 @@ - At this point your &matlab; + At this point the &matlab; installation is complete. The following steps apply - glue to connect it to your &os; system. + glue to connect it to the &os; system. License Manager Startup + - Create symlinks for the license manager scripts: + Create symlinks for the license manager + scripts: &prompt.root; ln -s $MATLAB/etc/lmboot /usr/local/etc/lmboot_TMW &prompt.root; ln -s $MATLAB/etc/lmdown /usr/local/etc/lmdown_TMW - Create a startup file at - /usr/local/etc/rc.d/flexlm.sh. The + Create a startup file named + /usr/local/etc/rc.d/flexlm. The example below is a modified version of the distributed - $MATLAB/etc/rc.lm.glnx86. The changes - are file locations, and startup of the license manager - under Linux emulation. + $MATLAB/etc/rc.lm.glnx86. The + changes are file locations and startup of the license + manager under &linux; emulation. #!/bin/sh case "$1" in @@ -755,28 +690,28 @@ The file must be made executable: - &prompt.root; chmod +x /usr/local/etc/rc.d/flexlm.sh + &prompt.root; chmod +x /usr/local/etc/rc.d/flexlm - You must also replace - username above with the name - of a valid user on your system (and not - root). + Replace username with the + name of a valid user on the system which is not + root. Start the license manager with the command: - &prompt.root; /usr/local/etc/rc.d/flexlm.sh start + &prompt.root; service flexlm start - + Linking the &java; Runtime Environment Change the &java; Runtime - Environment (JRE) link to one working under &os;: + Environment (JRE) link to one working under + &os;: &prompt.root; cd $MATLAB/sys/java/jre/glnx86/ &prompt.root; unlink jre; ln -s ./jre1.1.8 ./jre @@ -788,31 +723,30 @@ Place the following startup script in - /usr/local/bin/matlab: - + /usr/local/bin/matlab: #!/bin/sh /compat/linux/bin/sh /compat/linux/usr/local/matlab/bin/matlab "$@" - Then type the command + Then, type the command chmod +x /usr/local/bin/matlab. - Depending on your version of - emulators/linux_base, you - may run into errors when running this script. To avoid that, - edit the file + Depending on the version of + emulators/linux_base, + running this script may result in errors. To avoid errors, + edit /compat/linux/usr/local/matlab/bin/matlab, and change the line that says: if [ `expr "$lscmd" : '.*->.*'` -ne 0 ]; then - (in version 13.0.1 it is on line 410) to this - line: + to this line: if test -L $newbase; then @@ -826,30 +760,31 @@ - Create a file - $MATLAB/toolbox/local/finish.m, and - in it put the single line: + Create + $MATLAB/toolbox/local/finish.m + containing the single line: ! $MATLAB/bin/finish.sh - The $MATLAB is - literal. + + The $MATLAB is literal. + - In the same directory, you will find the files + The same directory contains finishsav.m and - finishdlg.m, which let you save - your workspace before quitting. If you use either of - them, insert the line above immediately after the - save command. + finishdlg.m, which allow the + workspace to be saved before quitting. If either file + is used, insert the line above immediately after the + save command. + - Create a file - $MATLAB/bin/finish.sh, which will - contain the following: + Create $MATLAB/bin/finish.sh + which contains the following: - #!/usr/compat/linux/bin/sh + #!/compat/linux/bin/sh (sleep 5; killall -1 matlab_helper) & exit 0 @@ -862,73 +797,82 @@ - + Using &matlab; - At this point you are ready to type - matlab and start using it. + At this point, matlab is ready for + use. - - Installing &oracle; + + While the Oracle website is unclear, the installation script is: + You are attempting to install 64-bit Oracle on a 32-bit operating + system. This is not supported and will not work. + + - MarcelMoolenaarContributed by - + + Marcel + Moolenaar + Contributed by + - - + + + Installing &oracle; applications Oracle - - Preface - This document describes the process of installing &oracle; 8.0.5 and - &oracle; 8.0.5.1 Enterprise Edition for Linux onto a FreeBSD - machine. - + This document describes the process of installing + &oracle; 8.0.5 and + &oracle; 8.0.5.1 Enterprise Edition + for &linux; onto a &os; machine. - Installing the Linux Environment + Installing the &linux; Environment + + Make sure emulators/linux_base + has been installed from the Ports Collection. - Make sure you have both emulators/linux_base and - devel/linux_devtools from the Ports Collection - installed. If you run into difficulties with these ports, - you may have to use - the packages or older versions available in the Ports Collection. - - If you want to run the intelligent agent, you will - also need to install the Red Hat Tcl package: - tcl-8.0.3-20.i386.rpm. The general command - for installing packages with the official RPM port (archivers/rpm) is: + To run the intelligent agent, install the Red Hat Tcl + package: tcl-8.0.3-20.i386.rpm. The + general command for installing RPMs with the + archivers/rpm port + is: - &prompt.root; rpm -i --ignoreos --root /compat/linux --dbpath /var/lib/rpm package + &prompt.root; rpm -i --ignoreos --root /compat/linux --dbpath /var/lib/rpm package - Installation of the package should not generate any errors. + This command should not generate any errors. Creating the &oracle; Environment - Before you can install &oracle;, you need to set up a proper - environment. This document only describes what to do - specially to run &oracle; for Linux on FreeBSD, not - what has been described in the &oracle; installation guide. - - - Kernel Tuning - kernel tuning - - As described in the &oracle; installation guide, you need to set - the maximum size of shared memory. Do not use - SHMMAX under FreeBSD. SHMMAX - is merely calculated out of SHMMAXPGS and - PGSIZE. Therefore define - SHMMAXPGS. All other options can be used as - described in the guide. For example: + Before installing &oracle;, set + up a proper environment. This section only describes how to + install &oracle; for &linux; on + &os;, not what has been described in the + &oracle; installation guide. + + + Kernel Tuning + + + kernel tuning + + + As described in the &oracle; + installation guide, the maximum size of shared memory needs + to be set. Do not use SHMMAX under &os; + as it is calculated from SHMMAXPGS and + PGSIZE. Therefore, define + SHMMAXPGS. All other options can be + used as described in the guide. For example: options SHMMAXPGS=10000 options SHMMNI=100 @@ -937,80 +881,80 @@ options SEMMNI=70 options SEMMSL=61 - Set these options to suit your intended use of &oracle;. + Set these options to suit the intended use of + &oracle;. - Also, make sure you have the following options in your kernel - configuration file: + Also, make sure the following options are in the + kernel configuration file: -options SYSVSHM #SysV shared memory + options SYSVSHM #SysV shared memory options SYSVSEM #SysV semaphores options SYSVMSG #SysV interprocess communication - + - &oracle; Account + &oracle; Account - Create an oracle account just as you would create any other - account. The oracle account is special only that you need to give - it a Linux shell. Add /compat/linux/bin/bash to - /etc/shells and set the shell for the oracle - account to /compat/linux/bin/bash. + Create a user account to be used as the + oracle account. Add + /compat/linux/bin/bash to + /etc/shells and set the shell for + the oracle account to + /compat/linux/bin/bash. - - Environment + + Environment - Besides the normal &oracle; variables, such as - ORACLE_HOME and ORACLE_SID you must - set the following environment variables: + Besides the normal &oracle; + variables, such as ORACLE_HOME and + ORACLE_SID set the following + environment variables: - - + + Variable - Value + LD_LIBRARY_PATH - $ORACLE_HOME/lib CLASSPATH - $ORACLE_HOME/jdbc/lib/classes111.zip PATH - /compat/linux/bin -/compat/linux/sbin -/compat/linux/usr/bin -/compat/linux/usr/sbin -/bin -/sbin -/usr/bin -/usr/sbin -/usr/local/bin -$ORACLE_HOME/bin + /compat/linux/sbin + /compat/linux/usr/bin + /compat/linux/usr/sbin + /bin + /sbin + /usr/bin + /usr/sbin + /usr/local/bin + $ORACLE_HOME/bin - It is advised to set all the environment variables in - .profile. A complete example is: + It is advised to set all the environment variables in + ~/.profile as follows: -ORACLE_BASE=/oracle; export ORACLE_BASE + ORACLE_BASE=/oracle; export ORACLE_BASE ORACLE_HOME=/oracle; export ORACLE_HOME LD_LIBRARY_PATH=$ORACLE_HOME/lib export LD_LIBRARY_PATH @@ -1028,18 +972,20 @@ Installing &oracle; - Due to a slight inconsistency in the Linux emulator, you need to - create a directory named .oracle in - /var/tmp before you start the installer. - Let it be owned by the oracle user. You - should be able to install &oracle; without any problems. If you have - problems, check your &oracle; distribution and/or configuration first! - After you have installed &oracle;, apply the patches described in the - next two subsections. - - A frequent problem is that the TCP protocol adapter is not - installed right. As a consequence, you cannot start any TCP listeners. - The following actions help solve this problem: + Before starting the installer, create a directory named + /var/tmp/.oracle which + is owned by the oracle user. The + installation of &oracle; should + work without any problems. If errors are encountered, check + the &oracle; distribution and + configuration. Once &oracle; is + installed, apply the patches described in the next two + subsections. + + A frequent error is that the TCP protocol adapter is not + installed correctly. As a consequence, no TCP listeners can + be started. The following actions help to solve this + problem: &prompt.root; cd $ORACLE_HOME/network/lib &prompt.root; make -f ins_network.mk ntcontab.o @@ -1048,20 +994,23 @@ &prompt.root; cd $ORACLE_HOME/network/lib &prompt.root; make -f ins_network.mk install - Do not forget to run root.sh again! + Do not forget to run root.sh + again. - - Patching root.sh + + Patching <filename>root.sh</filename> - When installing &oracle;, some actions, which need to be performed - as root, are recorded in a shell script called - root.sh. This script is - written in the orainst directory. Apply the - following patch to root.sh, to have it use to proper location of - chown or alternatively run the script under a - Linux native shell. + When installing &oracle;, + some actions, which need to be performed as + root, are recorded in a shell script + called root.sh. This script is + found in orainst. + Apply the following patch to root.sh + so that it can find the &os; location of + chown. Alternatively, run the script + under a &linux; native shell. - *** orainst/root.sh.orig Tue Oct 6 21:57:33 1998 + *** orainst/root.sh.orig Tue Oct 6 21:57:33 1998 --- orainst/root.sh Mon Dec 28 15:58:53 1998 *************** *** 31,37 **** @@ -1071,7 +1020,7 @@ ! CHOWN=/bin/chown # # Define variables to be used in this script ---- 31,37 ---- + --- 31,37 ---- # This is the default value for CHOWN # It will redefined later in this script for those ports # which have it conditionally defined in ss_install.h @@ -1079,35 +1028,36 @@ # # Define variables to be used in this script - When you do not install &oracle; from CD, you can patch the source - for root.sh. It is called - rthd.sh and is located in the - orainst directory in the source tree. - - - - Patching genclntsh - - The script genclntsh is used to create - a single shared client - library. It is used when building the demos. Apply the following - patch to comment out the definition of PATH: + If &oracle; is not installed + from CD, patch the source for root.sh. + It is called rthd.sh and is located in + orainst in the source + tree. + + + + Patching <filename>genclntsh</filename> + + The script genclntsh is used to create + a single shared client library when building the demos. Apply + the following patch to comment out the definition of + PATH: - *** bin/genclntsh.orig Wed Sep 30 07:37:19 1998 + *** bin/genclntsh.orig Wed Sep 30 07:37:19 1998 --- bin/genclntsh Tue Dec 22 15:36:49 1998 *************** *** 32,38 **** # # Explicit path to ensure that we're using the correct commands #PATH=/usr/bin:/usr/ccs/bin export PATH -! PATH=/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin export PATH +! PATH=/usr/local/bin:/bin:/usr/bin export PATH # # each product MUST provide a $PRODUCT/admin/shrept.lst --- 32,38 ---- # # Explicit path to ensure that we're using the correct commands #PATH=/usr/bin:/usr/ccs/bin export PATH -! #PATH=/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin export PATH +! #PATH=/usr/local/bin:/bin:/usr/bin: export PATH # # each product MUST provide a $PRODUCT/admin/shrept.lst @@ -1116,2166 +1066,109 @@ Running &oracle; - When you have followed the instructions, you should be able to run - &oracle; as if it was run on Linux - itself. + After following these instructions, + &oracle; should run as if it was + running on &linux;. + ?> - - Installing &sap.r3; - - HolgerKippContributed by - - - - ValentinoVaschettoOriginal version converted to SGML by - - - - - - - applications - SAP R/3 - - - Installations of &sap; Systems using FreeBSD will not be - supported by the &sap; support team — they only offer support - for certified platforms. - - - Preface - - This document describes a possible way of installing a - &sap.r3; System - with &oracle; Database - for Linux onto a FreeBSD machine, including the installation - of FreeBSD and &oracle;. Two different - configurations will be described: - - - - &sap.r3; 4.6B (IDES) with - &oracle; 8.0.5 on FreeBSD 4.3-STABLE - - - - &sap.r3; 4.6C with - &oracle; 8.1.7 on FreeBSD 4.5-STABLE - - - - Even though this document tries to describe all important - steps in a greater detail, it is not intended as a replacement - for the &oracle; and - &sap.r3; installation guides. - - Please see the documentation that comes with the - &sap.r3; - Linux edition for &sap; and - &oracle; specific questions, as well - as resources from &oracle; and - &sap; OSS. - - - - Software - - The following CD-ROMs have been used for &sap; installations: - - - &sap.r3; 4.6B, &oracle; 8.0.5 - - - - - - Name Number Description - - - - - KERNEL 51009113 SAP Kernel Oracle / - Installation / AIX, Linux, Solaris - - - - RDBMS 51007558 Oracle / RDBMS 8.0.5.X / - Linux - - - - EXPORT1 51010208 IDES / DB-Export / - Disc 1 of 6 - - - - EXPORT2 51010209 IDES / DB-Export / - Disc 2 of 6 - - - - EXPORT3 51010210 IDES / DB-Export / - Disc 3 of 6 - - - - EXPORT4 51010211 IDES / DB-Export / - Disc 4 of 6 - - - - EXPORT5 51010212 IDES / DB-Export / - Disc 5 of 6 - - - - EXPORT6 51010213 IDES / DB-Export / - Disc 6 of 6 - - - - - - Additionally, we used the &oracle; 8 - Server (Pre-production version 8.0.5 for Linux, - Kernel Version 2.0.33) CD which is not really necessary, and - FreeBSD 4.3-STABLE (it was only a few days past 4.3 - RELEASE). - - - - &sap.r3; 4.6C SR2, &oracle; 8.1.7 - - - - - - Name Number Description - - - - - - KERNEL 51014004 SAP Kernel Oracle / - SAP Kernel Version 4.6D / DEC, Linux - - - - RDBMS 51012930 Oracle 8.1.7/ RDBMS / - Linux - - - - EXPORT1 51013953 Release 4.6C SR2 / Export - / Disc 1 of 4 - - - - EXPORT1 51013953 Release 4.6C SR2 / Export - / Disc 2 of 4 - - - - EXPORT1 51013953 Release 4.6C SR2 / Export - / Disc 3 of 4 - - - - EXPORT1 51013953 Release 4.6C SR2 / Export - / Disc 4 of 4 - - - - LANG1 51013954 Release 4.6C SR2 / - Language / DE, EN, FR / Disc 1 of 3 - - - - - - Depending on the languages you would like to install, additional - language CDs might be necessary. Here we are just using DE and EN, so - the first language CD is the only one needed. As a little note, the - numbers for all four EXPORT CDs are identical. All three language CDs - also have the same number (this is different from the 4.6B IDES - release CD numbering). At the time of writing this installation is - running on FreeBSD 4.5-STABLE (20.03.2002). - - - - - &sap; Notes - - The following notes should be read before installing - &sap.r3; and proved to be useful - during installation: - - - &sap.r3; 4.6B, &oracle; 8.0.5 - - - - - - Number - Title - - - - - - 0171356 SAP Software on Linux: Essential - Comments - - - - 0201147 INST: 4.6C R/3 Inst. on UNIX - - Oracle - - - - 0373203 Update / Migration Oracle 8.0.5 --> - 8.0.6/8.1.6 LINUX - - - - 0072984 Release of Digital UNIX 4.0B for - Oracle - - - - 0130581 R3SETUP step DIPGNTAB terminates - - - - 0144978 Your system has not been installed - correctly - - - - 0162266 Questions and tips for R3SETUP on Windows - NT / W2K - - - - - - - - &sap.r3; 4.6C, &oracle; 8.1.7 - - - - - - Number - Title - - - - - 0015023 Initializing table TCPDB (RSXP0004) - (EBCDIC) - - - - 0045619 R/3 with several languages or - typefaces - - - - 0171356 SAP Software on Linux: Essential - Comments - - - - 0195603 RedHat 6.1 Enterprise version: - Known problems - - - - 0212876 The new archiving tool SAPCAR - - - - 0300900 Linux: Released DELL Hardware - - - - 0377187 RedHat 6.2: important remarks - - - - 0387074 INST: R/3 4.6C SR2 Installation on - UNIX - - - - 0387077 INST: R/3 4.6C SR2 Inst. on UNIX - - Oracle - - - - 0387078 SAP Software on UNIX: OS Dependencies - 4.6C SR2 - - - - - - - - - Hardware Requirements - - The following equipment is sufficient for the installation - of a &sap.r3; System. For production - use, a more exact sizing is of course needed: - - - - - - Component - 4.6B - 4.6C - - - - - Processor - 2 x 800MHz &pentium; III - 2 x 800MHz &pentium; III - - - - Memory - 1GB ECC - 2GB ECC - - - - Hard Disk Space - 50-60GB (IDES) - 50-60GB (IDES) - - - - - - For use in production, &xeon; Processors with large cache, - high-speed disk access (SCSI, RAID hardware controller), USV - and ECC-RAM is recommended. The large amount of hard disk - space is due to the preconfigured IDES System, which creates - 27 GB of database files during installation. This space is - also sufficient for initial production systems and application - data. - - - &sap.r3; 4.6B, &oracle; 8.0.5 - - The following off-the-shelf hardware was used: a dual processor - board with 2 800 MHz &pentium; III processors, &adaptec; 29160 Ultra160 - SCSI adapter (for accessing a 40/80 GB DLT tape drive and CDROM), - &mylex; &acceleraid; (2 channels, firmware 6.00-1-00 with 32 MB RAM). - To the &mylex; RAID controller are attached two 17 GB hard disks - (mirrored) and four 36 GB hard disks (RAID level 5). - - - - &sap.r3; 4.6C, &oracle; 8.1.7 - - For this installation a &dell; &poweredge; 2500 was used: a - dual processor board with two 1000 MHz &pentium; III processors - (256 kB Cache), 2 GB PC133 ECC SDRAM, PERC/3 DC PCI RAID Controller - with 128 MB, and an EIDE DVD-ROM drive. To the RAID controller are - attached two 18 GB hard disks (mirrored) and four 36 GB hard disks - (RAID level 5). - - - - - Installation of FreeBSD - - First you have to install FreeBSD. There are several ways to do - this, for more information read the . - - - Disk Layout - - To keep it simple, the same disk layout both for the - &sap.r3; 46B and &sap.r3; 46C - SR2 installation was used. Only the device names - changed, as the installations were on different hardware (/dev/da - and /dev/amr respectively, so if using an AMI &megaraid;, one will see - /dev/amr0s1a instead of /dev/da0s1a): - - - - - - File system - Size (1k-blocks) - Size (GB) - Mounted on - - - - - /dev/da0s1a - 1.016.303 - 1 - / - - - - /dev/da0s1b - - 6 - swap - - - - /dev/da0s1e - 2.032.623 - 2 - /var - - - - /dev/da0s1f - 8.205.339 - 8 - /usr - - - - /dev/da1s1e - 45.734.361 - 45 - /compat/linux/oracle - - - - /dev/da1s1f - 2.032.623 - 2 - /compat/linux/sapmnt - - - - /dev/da1s1g - 2.032.623 - 2 - /compat/linux/usr/sap - - - - - - Configure and initialize the two logical drives - with the &mylex; or PERC/3 RAID software beforehand. - The software can be started during the - BIOS boot phase. - - Please note that this disk layout differs slightly from - the &sap; recommendations, as &sap; suggests mounting the - &oracle; subdirectories (and some others) separately — we - decided to just create them as real subdirectories for - simplicity. - - - - <command>make world</command> and a New Kernel - - Download the latest -STABLE sources. Rebuild world and your - custom kernel after configuring your kernel configuration file. - Here you should also include the - kernel parameters - which are required for both &sap.r3; - and &oracle;. - - - - - Installing the Linux Environment - - - Installing the Linux Base System - - First the linux_base - port needs to be installed (as root): - - &prompt.root; cd /usr/ports/emulators/linux_base -&prompt.root; make install distclean - - - - - - Installing Linux Development Environment - - The Linux development environment is needed, if you want to install - &oracle; on FreeBSD according to the - : - - &prompt.root; cd /usr/ports/devel/linux_devtools -&prompt.root; make install distclean - - The Linux development environment has only been installed for the &sap.r3; - 46B IDES installation. It is not needed, if - the &oracle; DB is not relinked on the - FreeBSD system. This is the case if you are using the - &oracle; tarball from a Linux system. - - - - - - Installing the Necessary RPMs - RPMs - - To start the R3SETUP program, PAM support is needed. - During the first &sap; Installation on FreeBSD 4.3-STABLE we - tried to install PAM with all the required packages and - finally forced the installation of the PAM package, which - worked. For &sap.r3; 4.6C SR2 we - directly forced the installation of the PAM RPM, which also - works, so it seems the dependent packages are not needed: - - -&prompt.root; rpm -i --ignoreos --nodeps --root /compat/linux --dbpath /var/lib/rpm \ -pam-0.68-7.i386.rpm - - For &oracle; 8.0.5 to run the - intelligent agent, we also had to install the RedHat Tcl package - tcl-8.0.5-30.i386.rpm (otherwise the - relinking during &oracle; installation - will not work). There are some other issues regarding - relinking of &oracle;, but that is - a &oracle; Linux issue, not FreeBSD specific. - - - - - Some Additional Hints - - It might also be a good idea to add linprocfs - to /etc/fstab, for more information, see the &man.linprocfs.5; manual page. - Another parameter to set is kern.fallback_elf_brand=3 - which is done in the file /etc/sysctl.conf. - - - - - Creating the &sap.r3; Environment - - - Creating the Necessary File Systems and Mountpoints - - For a simple installation, it is sufficient to create the - following file systems: - - - - - - mount point - size in GB - - - - - /compat/linux/oracle - 45 GB - - - - /compat/linux/sapmnt - 2 GB - - - - /compat/linux/usr/sap - 2 GB - - - - - - It is also necessary to created some links. Otherwise - the &sap; Installer will complain, as it is checking the - created links: - - &prompt.root; ln -s /compat/linux/oracle /oracle -&prompt.root; ln -s /compat/linux/sapmnt /sapmnt -&prompt.root; ln -s /compat/linux/usr/sap /usr/sap - - Possible error message during installation (here with - System PRD and the - &sap.r3; 4.6C SR2 - installation): - - INFO 2002-03-19 16:45:36 R3LINKS_IND_IND SyLinkCreate:200 - Checking existence of symbolic link /usr/sap/PRD/SYS/exe/dbg to - /sapmnt/PRD/exe. Creating if it does not exist... - -WARNING 2002-03-19 16:45:36 R3LINKS_IND_IND SyLinkCreate:400 - Link /usr/sap/PRD/SYS/exe/dbg exists but it points to file - /compat/linux/sapmnt/PRD/exe instead of /sapmnt/PRD/exe. The - program cannot go on as long as this link exists at this - location. Move the link to another location. - -ERROR 2002-03-19 16:45:36 R3LINKS_IND_IND Ins_SetupLinks:0 - can not setup link '/usr/sap/PRD/SYS/exe/dbg' with content - '/sapmnt/PRD/exe' - - - - Creating Users and Directories - - &sap.r3; needs two users and - three groups. The user names depend on the - &sap; system ID (SID) which consists - of three letters. Some of these SIDs are reserved - by &sap; (for example - SAP and NIX. For a - complete list please see the &sap; documentation). For the IDES - installation we used IDS, for the - 4.6C SR2 installation PRD, as that system - is intended for production use. We have - therefore the following groups (group IDs might differ, these - are just the values we used with our installation): - - - - - - group ID - group name - description - - - - - 100 - dba - Data Base Administrator - - - 101 - sapsys - &sap; System - - - 102 - oper - Data Base Operator - - - - - - For a default &oracle; installation, only group - dba is used. As - oper group, one also uses group - dba (see &oracle; and - &sap; documentation for further information). - - We also need the following users: - - - - - - user ID - user name - generic name - group - additional groups - description - - - - - 1000 - idsadm/prdadm - sidadm - sapsys - oper - &sap; Administrator - - - 1002 - oraids/oraprd - orasid - dba - oper - &oracle; Administrator - - - - - - Adding the users with &man.adduser.8; - requires the following (please note shell and home - directory) entries for &sap; Administrator: - - Name: sidadm -Password: ****** -Fullname: SAP Administrator SID -Uid: 1000 -Gid: 101 (sapsys) -Class: -Groups: sapsys dba -HOME: /home/sidadm -Shell: bash (/compat/linux/bin/bash) - - and for &oracle; Administrator: - - Name: orasid -Password: ****** -Fullname: Oracle Administrator SID -Uid: 1002 -Gid: 100 (dba) -Class: -Groups: dba -HOME: /oracle/sid -Shell: bash (/compat/linux/bin/bash) - - This should also include group - oper in case you are using both - groups dba and - oper. - - - - - Creating Directories - - These directories are usually created as separate - file systems. This depends entirely on your requirements. We - choose to create them as simple directories, as they are all - located on the same RAID 5 anyway: - - First we will set owners and rights of some directories (as - user root): - - &prompt.root; chmod 775 /oracle -&prompt.root; chmod 777 /sapmnt -&prompt.root; chown root:dba /oracle -&prompt.root; chown sidadm:sapsys /compat/linux/usr/sap -&prompt.root; chmod 775 /compat/linux/usr/sap - - Second we will create directories as user - orasid. These - will all be subdirectories of - /oracle/SID: - - &prompt.root; su - orasid -&prompt.root; cd /oracle/SID -&prompt.root; mkdir mirrlogA mirrlogB origlogA origlogB -&prompt.root; mkdir sapdata1 sapdata2 sapdata3 sapdata4 sapdata5 sapdata6 -&prompt.root; mkdir saparch sapreorg -&prompt.root; exit - - For the &oracle; 8.1.7 installation - some additional directories are needed: - - &prompt.root; su - orasid -&prompt.root; cd /oracle -&prompt.root; mkdir 805_32 -&prompt.root; mkdir client stage -&prompt.root; mkdir client/80x_32 -&prompt.root; mkdir stage/817_32 -&prompt.root; cd /oracle/SID -&prompt.root; mkdir 817_32 - - The directory client/80x_32 is used - with exactly this name. Do not replace the x - with some number or anything. - - In the third step we create directories as user - sidadm: - - &prompt.root; su - sidadm -&prompt.root; cd /usr/sap -&prompt.root; mkdir SID -&prompt.root; mkdir trans -&prompt.root; exit - - - - Entries in <filename>/etc/services</filename> - - &sap.r3; requires some entries in file - /etc/services, which will not be set - correctly during installation under FreeBSD. Please add the - following entries (you need at least those entries - corresponding to the instance number — in this case, - 00. It will do no harm adding all - entries from 00 to - 99 for dp, - gw, sp and - ms). If you are going to use a SAProuter - or need to access &sap; OSS, you also need 99, - as port 3299 is usually used for the SAProuter process on the - target system: - - -sapdp00 3200/tcp # SAP Dispatcher. 3200 + Instance-Number -sapgw00 3300/tcp # SAP Gateway. 3300 + Instance-Number -sapsp00 3400/tcp # 3400 + Instance-Number -sapms00 3500/tcp # 3500 + Instance-Number -sapmsSID 3600/tcp # SAP Message Server. 3600 + Instance-Number -sapgw00s 4800/tcp # SAP Secure Gateway 4800 + Instance-Number - - - - Necessary Locales - locale - - &sap; requires at least two locales that are not part of - the default RedHat installation. &sap; offers the required - RPMs as download from their FTP server (which is only - accessible if you are a customer with OSS access). See note - 0171356 for a list of RPMs you need. - - It is also possible to just create appropriate links - (for example from de_DE and - en_US ), but we would not recommend this - for a production system (so far it worked with the IDES - system without any problems, though). The following locales - are needed: - - de_DE.ISO-8859-1 -en_US.ISO-8859-1 - - Create the links like this: - - &prompt.root; cd /compat/linux/usr/share/locale -&prompt.root; ln -s de_DE de_DE.ISO-8859-1 -&prompt.root; ln -s en_US en_US.ISO-8859-1 - - If they are not present, there will be some problems - during the installation. If these are then subsequently - ignored (by setting the STATUS of the offending steps to - OK in file CENTRDB.R3S), it will be impossible to log onto - the &sap; system without some additional effort. - - - - Kernel Tuning - kernel tuning - - &sap.r3; systems need a lot of resources. We therefore - added the following parameters to the kernel configuration file: - - # Set these for memory pigs (SAP and Oracle): -options MAXDSIZ="(1024*1024*1024)" -options DFLDSIZ="(1024*1024*1024)" -# System V options needed. -options SYSVSHM #SYSV-style shared memory -options SHMMAXPGS=262144 #max amount of shared mem. pages -#options SHMMAXPGS=393216 #use this for the 46C inst.parameters -options SHMMNI=256 #max number of shared memory ident if. -options SHMSEG=100 #max shared mem.segs per process -options SYSVMSG #SYSV-style message queues -options MSGSEG=32767 #max num. of mes.segments in system -options MSGSSZ=32 #size of msg-seg. MUST be power of 2 -options MSGMNB=65535 #max char. per message queue -options MSGTQL=2046 #max amount of msgs in system -options SYSVSEM #SYSV-style semaphores -options SEMMNU=256 #number of semaphore UNDO structures -options SEMMNS=1024 #number of semaphores in system -options SEMMNI=520 #number of semaphore identifiers -options SEMUME=100 #number of UNDO keys - - The minimum values are specified in the documentation that - comes from &sap;. As there is no description for Linux, see the - HP-UX section (32-bit) for further information. As the system - for the 4.6C SR2 installation has more main memory, the shared - segments can be larger both for &sap; - and &oracle;, therefore choose a larger - number of shared memory pages. - - With the default installation of FreeBSD on &i386;, - leave MAXDSIZ and DFLDSIZ at 1 GB maximum. Otherwise, strange - errors like ORA-27102: out of memory and - Linux Error: 12: Cannot allocate memory - might happen. - - - - - Installing &sap.r3; - - - Preparing &sap; CDROMs - - There are many CDROMs to mount and unmount during the - installation. Assuming you have enough CDROM drives, you - can just mount them all. We decided to copy the CDROMs - contents to corresponding directories: - - /oracle/SID/sapreorg/cd-name - - where cd-name was one of KERNEL, - RDBMS, EXPORT1, - EXPORT2, EXPORT3, - EXPORT4, EXPORT5 and - EXPORT6 for the 4.6B/IDES installation, and - KERNEL, RDBMS, - DISK1, DISK2, - DISK3, DISK4 and - LANG for the 4.6C SR2 installation. All the - filenames on the mounted CDs should be in capital letters, - otherwise use the option for mounting. So use the following - commands: - - &prompt.root; mount_cd9660 -g /dev/cd0a /mnt -&prompt.root; cp -R /mnt/* /oracle/SID/sapreorg/cd-name -&prompt.root; umount /mnt - - - - Running the Installation Script - - First you have to prepare an install directory: - - &prompt.root; cd /oracle/SID/sapreorg -&prompt.root; mkdir install -&prompt.root; cd install - - Then the installation script is started, which will copy nearly - all the relevant files into the install directory: - - &prompt.root; /oracle/SID/sapreorg/KERNEL/UNIX/INSTTOOL.SH - - The IDES installation (4.6B) comes with a fully customized - &sap.r3; demonstration system, so there are six instead of just three - EXPORT CDs. At this point the installation template - CENTRDB.R3S is for installing a standard - central instance (&r3; and database), not the IDES central - instance, so one needs to copy the corresponding CENTRDB.R3S - from the EXPORT1 directory, otherwise R3SETUP will only ask - for three EXPORT CDs. - - The newer &sap; 4.6C SR2 release - comes with four EXPORT CDs. The parameter file that controls - the installation steps is CENTRAL.R3S. - Contrary to earlier releases there are no separate installation - templates for a central instance with or without database. - &sap; is using a separate template for database installation. To restart - the installation later it is however sufficient to restart with - the original file. - - During and after installation, &sap; requires - hostname to return the computer name - only, not the fully qualified domain name. So either - set the hostname accordingly, or set an alias with - alias hostname='hostname -s' for - both orasid and - sidadm (and for - root at least during installation - steps performed as root). It is also - possible to adjust the installed .profile and .login files of - both users that are installed during - &sap; installation. - - - - Start <command>R3SETUP</command> 4.6B - - Make sure LD_LIBRARY_PATH is set correctly: - - &prompt.root; export LD_LIBRARY_PATH=/oracle/IDS/lib:/sapmnt/IDS/exe:/oracle/805_32/lib - - Start R3SETUP as root from - installation directory: - - &prompt.root; cd /oracle/IDS/sapreorg/install -&prompt.root; ./R3SETUP -f CENTRDB.R3S - - The script then asks some questions (defaults in brackets, - followed by actual input): - - - - - - Question - Default - Input - - - - - Enter SAP System ID - [C11] - IDSEnter - - - Enter SAP Instance Number - [00] - Enter - - - Enter SAPMOUNT Directory - [/sapmnt] - Enter - - - Enter name of SAP central host - [troubadix.domain.de] - Enter - - - Enter name of SAP db host - [troubadix] - Enter - - - Select character set - [1] (WE8DEC) - Enter - - - Enter Oracle server version (1) Oracle 8.0.5, (2) Oracle 8.0.6, (3) Oracle 8.1.5, (4) Oracle 8.1.6 - - 1Enter - - - Extract Oracle Client archive - [1] (Yes, extract) - Enter - - - Enter path to KERNEL CD - [/sapcd] - /oracle/IDS/sapreorg/KERNEL - - - Enter path to RDBMS CD - [/sapcd] - /oracle/IDS/sapreorg/RDBMS - - - Enter path to EXPORT1 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT1 - - - Directory to copy EXPORT1 CD - [/oracle/IDS/sapreorg/CD4_DIR] - Enter - - - Enter path to EXPORT2 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT2 - - - Directory to copy EXPORT2 CD - [/oracle/IDS/sapreorg/CD5_DIR] - Enter - - - Enter path to EXPORT3 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT3 - - - Directory to copy EXPORT3 CD - [/oracle/IDS/sapreorg/CD6_DIR] - Enter - - - Enter path to EXPORT4 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT4 - - - Directory to copy EXPORT4 CD - [/oracle/IDS/sapreorg/CD7_DIR] - Enter - - - Enter path to EXPORT5 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT5 - - - Directory to copy EXPORT5 CD - [/oracle/IDS/sapreorg/CD8_DIR] - Enter - - - Enter path to EXPORT6 CD - [/sapcd] - /oracle/IDS/sapreorg/EXPORT6 - - - Directory to copy EXPORT6 CD - [/oracle/IDS/sapreorg/CD9_DIR] - Enter - - - Enter amount of RAM for SAP + DB - - 850Enter (in Megabytes) - - - Service Entry Message Server - [3600] - Enter - - - Enter Group-ID of sapsys - [101] - Enter - - - Enter Group-ID of oper - [102] - Enter - - - Enter Group-ID of dba - [100] - Enter - - - Enter User-ID of sidadm - [1000] - Enter - - - Enter User-ID of orasid - [1002] - Enter - - - Number of parallel procs - [2] - Enter - - - - - - If you had not copied the CDs to the different locations, - then the &sap; installer cannot find the CD needed (identified - by the LABEL.ASC file on the CD) and would - then ask you to insert and mount the CD and confirm or enter - the mount path. - - The CENTRDB.R3S might not be - error free. In our case, it requested EXPORT4 CD again but - indicated the correct key (6_LOCATION, then 7_LOCATION - etc.), so one can just continue with entering the correct - values. - - Apart from some problems mentioned below, everything - should go straight through up to the point where the &oracle; - database software needs to be installed. - - - - Start <command>R3SETUP</command> 4.6C SR2 - - Make sure LD_LIBRARY_PATH is set correctly. This is a - different value from the 4.6B installation with - &oracle; 8.0.5: - - &prompt.root; export LD_LIBRARY_PATH=/sapmnt/PRD/exe:/oracle/PRD/817_32/lib - - Start R3SETUP as user root from installation directory: - - &prompt.root; cd /oracle/PRD/sapreorg/install -&prompt.root; ./R3SETUP -f CENTRAL.R3S - - The script then asks some questions (defaults in brackets, - followed by actual input): - - - - - - Question - Default - Input - - - - - Enter SAP System ID - [C11] - PRDEnter - - - Enter SAP Instance Number - [00] - Enter - - - Enter SAPMOUNT Directory - [/sapmnt] - Enter - - - Enter name of SAP central host - [majestix] - Enter - - - Enter Database System ID - [PRD] - PRDEnter - - - Enter name of SAP db host - [majestix] - Enter - - - Select character set - [1] (WE8DEC) - Enter - - - Enter Oracle server version (2) Oracle 8.1.7 - - 2Enter - - - Extract Oracle Client archive - [1] (Yes, extract) - Enter - - - Enter path to KERNEL CD - [/sapcd] - /oracle/PRD/sapreorg/KERNEL - - - Enter amount of RAM for SAP + DB - 2044 - 1800Enter (in Megabytes) - - - Service Entry Message Server - [3600] - Enter - - - Enter Group-ID of sapsys - [100] - Enter - - - Enter Group-ID of oper - [101] - Enter - - - Enter Group-ID of dba - [102] - Enter - - - Enter User-ID of oraprd - [1002] - Enter - - - Enter User-ID of prdadm - [1000] - Enter - - - LDAP support - - 3Enter (no support) - - - Installation step completed - [1] (continue) - Enter - - - Choose installation service - [1] (DB inst,file) - Enter - - - - - - So far, creation of users gives an error during - installation in phases OSUSERDBSID_IND_ORA (for creating - user orasid) and - OSUSERSIDADM_IND_ORA (creating user - sidadm). - - Apart from some problems mentioned below, everything - should go straight through up to the point where the &oracle; - database software needs to be installed. - - - - - Installing &oracle; 8.0.5 - - Please see the corresponding &sap; Notes and &oracle; Readmes - regarding Linux and &oracle; DB for possible problems. Most if - not all problems stem from incompatible libraries. - - For more information on installing &oracle;, refer to the Installing &oracle; - chapter. - - - - Installing the &oracle; 8.0.5 with <command>orainst</command> - - If &oracle; 8.0.5 is to be - used, some additional libraries are needed for successfully - relinking, as &oracle; 8.0.5 was linked with an old glibc - (RedHat 6.0), but RedHat 6.1 already uses a new glibc. So - you have to install the following additional packages to - ensure that linking will work: - - compat-libs-5.2-2.i386.rpm - compat-glibc-5.2-2.0.7.2.i386.rpm - compat-egcs-5.2-1.0.3a.1.i386.rpm - compat-egcs-c++-5.2-1.0.3a.1.i386.rpm - compat-binutils-5.2-2.9.1.0.23.1.i386.rpm - - See the corresponding &sap; Notes or &oracle; Readmes for - further information. If this is no option (at the time of - installation we did not have enough time to check this), one - could use the original binaries, or use the relinked - binaries from an original RedHat system. - - For compiling the intelligent agent, the RedHat Tcl - package must be installed. If you cannot get - tcl-8.0.3-20.i386.rpm, a newer one like - tcl-8.0.5-30.i386.rpm for RedHat 6.1 - should also do. - - Apart from relinking, the installation is - straightforward: - - &prompt.root; su - oraids -&prompt.root; export TERM=xterm -&prompt.root; export ORACLE_TERM=xterm -&prompt.root; export ORACLE_HOME=/oracle/IDS -&prompt.root; cd $ORACLE_HOME/orainst_sap -&prompt.root; ./orainst - - Confirm all screens with Enter until the software is - installed, except that one has to deselect the - &oracle; On-Line Text Viewer, as this is - not currently available for Linux. &oracle; then wants to - relink with i386-glibc20-linux-gcc - instead of the available gcc, - egcs or i386-redhat-linux-gcc - . - - Due to time constrains we decided to use the binaries - from an &oracle; 8.0.5 PreProduction - release, after the first - attempt at getting the version from the RDBMS CD working, - failed, and finding and accessing the correct RPMs was a - nightmare at that time. - - - - - Installing the &oracle; 8.0.5 Pre-production Release for - Linux (Kernel 2.0.33) - - This installation is quite easy. Mount the CD, start the - installer. It will then ask for the location of the &oracle; - home directory, and copy all binaries there. We did not - delete the remains of our previous RDBMS installation tries, - though. - - Afterwards, &oracle; Database could be started with no - problems. - - - - - Installing the &oracle; 8.1.7 Linux Tarball - Take the tarball oracle81732.tgz you - produced from the installation directory on a Linux system - and untar it to /oracle/SID/817_32/. - - - - Continue with &sap.r3; Installation - - First check the environment settings of users - idsamd - (sidadm) and - oraids (orasid). They should now - both have the files .profile, - .login and .cshrc - which are all using hostname. In case the - system's hostname is the fully qualified name, you need to - change hostname to hostname - -s within all three files. - - - Database Load - - Afterwards, R3SETUP can either be restarted or continued - (depending on whether exit was chosen or not). R3SETUP then - creates the tablespaces and loads the data (for 46B IDES, from - EXPORT1 to EXPORT6, for 46C from DISK1 to DISK4) with R3load - into the database. - - When the database load is finished (might take a few - hours), some passwords are requested. For test - installations, one can use the well known default passwords - (use different ones if security is an issue!): - - - - - - Question - Input - - - - - Enter Password for sapr3 - sapEnter - - - Confirum Password for sapr3 - sapEnter - - - Enter Password for sys - change_on_installEnter - - - Confirm Password for sys - change_on_installEnter - - - Enter Password for system - managerEnter - - - Confirm Password for system - managerEnter - - - - - - At this point We had a few problems with - dipgntab during the 4.6B - installation. - - - - Listener - - Start the &oracle; Listener as user - orasid as follows: - - &prompt.user; umask 0; lsnrctl start - - Otherwise you might get the error ORA-12546 as the sockets will not - have the correct permissions. See &sap; Note 072984. - - - - Updating MNLS Tables - If you plan to import non-Latin-1 languages into the &sap; system, - you have to update the Multi National Language Support tables. - This is described in the &sap; OSS Notes 15023 and 45619. Otherwise, - you can skip this question during &sap; installation. - If you do not need MNLS, it is still necessary to check - the table TCPDB and initializing it if this has not been done. See - &sap; note 0015023 and 0045619 for further information. - - - - - Post-installation Steps - - - Request &sap.r3; License Key - - You have to request your &sap.r3; License Key. This is needed, - as the temporary license that was installed during installation - is only valid for four weeks. First get the hardware key. Log - on as user idsadm and call - saplicense: - - &prompt.root; /sapmnt/IDS/exe/saplicense -get - - Calling saplicense without parameters gives - a list of options. Upon receiving the license key, it can be - installed using: - - &prompt.root; /sapmnt/IDS/exe/saplicense -install - - You are then required to enter the following values: - - SAP SYSTEM ID = SID, 3 chars -CUSTOMER KEY = hardware key, 11 chars -INSTALLATION NO = installation, 10 digits -EXPIRATION DATE = yyyymmdd, usually "99991231" -LICENSE KEY = license key, 24 chars - - - - Creating Users - - Create a user within client 000 (for some tasks required - to be done within client 000, but with a user different from - users sap* and - ddic). As a user name, We usually choose - wartung (or - service in English). Profiles - required are sap_new and - sap_all. For additional safety the - passwords of default users within all clients should be - changed (this includes users sap* and - ddic). - - - - Configure Transport System, Profile, Operation Modes, Etc. - - Within client 000, user different from ddic - and sap*, do at least the following: - - - - - - Task - Transaction - - - - - Configure Transport System, e.g. as Stand-Alone - Transport Domain Entity - STMS - - - Create / Edit Profile for System - RZ10 - - - Maintain Operation Modes and Instances - RZ04 - - - - - - These and all the other post-installation steps are - thoroughly described in &sap; installation guides. - - - - Edit <filename>initsid.sap</filename> (<filename>initIDS.sap</filename>) - - The file /oracle/IDS/dbs/initIDS.sap - contains the &sap; backup profile. Here the size of the tape to - be used, type of compression and so on need to be defined. To - get this running with sapdba / - brbackup, we changed the following values: - - compress = hardware -archive_function = copy_delete_save -cpio_flags = "-ov --format=newc --block-size=128 --quiet" -cpio_in_flags = "-iuv --block-size=128 --quiet" -tape_size = 38000M -tape_address = /dev/nsa0 -tape_address_rew = /dev/sa0 - - Explanations: - - compress: The tape we use is a HP DLT1 - which does hardware compression. - - archive_function: This defines the - default behavior for saving &oracle; archive logs: new logfiles - are saved to tape, already saved logfiles are saved again and - are then deleted. This prevents lots of trouble if you need to - recover the database, and one of the archive-tapes has gone - bad. - - cpio_flags: Default is to use which - sets block size to 5120 Bytes. For DLT Tapes, HP recommends at - least 32 K block size, so we used for - 64 K. is needed because we have inode numbers greater than - 65535. The last option is needed as otherwise - brbackup - complains as soon as cpio outputs the - numbers of blocks saved. - - cpio_in_flags: Flags needed for - loading data back from tape. Format is recognized - automatically. - - tape_size: This usually gives the raw - storage capability of the tape. For security reason (we use - hardware compression), the value is slightly lower than the - actual value. - - tape_address: The non-rewindable - device to be used with cpio. - - tape_address_rew: The rewindable device to be - used with cpio. - - - - Configuration Issues after Installation - - The following &sap; parameters should be tuned after - installation (examples for IDES 46B, 1 GB memory): - - - - - - Name - Value - - - - - ztta/roll_extension - 250000000 - - - abap/heap_area_dia - 300000000 - - - abap/heap_area_nondia - 400000000 - - - em/initial_size_MB - 256 - - - em/blocksize_kB - 1024 - - - ipc/shm_psize_40 - 70000000 - - - - - - &sap; Note 0013026: - - - - - - Name - Value - - - - - ztta/dynpro_area - 2500000 - - - - - - &sap; Note 0157246: - - - - - - Name - Value - - - - - rdisp/ROLL_MAXFS - 16000 - - - rdisp/PG_MAXFS - 30000 - - - - - - - With the above parameters, on a system with 1 gigabyte - of memory, one may find memory consumption similar to: - - Mem: 547M Active, 305M Inact, 109M Wired, 40M Cache, 112M Buf, 3492K Free - - - - - - Problems during Installation - - - Restart <command>R3SETUP</command> after Fixing a Problem - - R3SETUP stops if it encounters an error. If you have - looked at the corresponding logfiles and fixed the error, - you have to start R3SETUP again, usually selecting REPEAT - as option for the last step R3SETUP complained about. - - To restart R3SETUP, just start it with the corresponding - R3S file: - - &prompt.root; ./R3SETUP -f CENTRDB.R3S - - for 4.6B, or with - - &prompt.root; ./R3SETUP -f CENTRAL.R3S - - for 4.6C, no matter whether the error occurred - with CENTRAL.R3S or - DATABASE.R3S. - - At some stages, R3SETUP assumes that both database - and &sap; processes are up and running (as those were steps it - already completed). Should errors occur and for example the - database could not be started, you have to start both database - and &sap; by hand after you fixed the errors and before starting - R3SETUP again. - Do not forget to also start the &oracle; listener again (as - orasid with - umask 0; lsnrctl start) if it was also - stopped (for example due to a necessary reboot of the - system). - - - - - OSUSERSIDADM_IND_ORA during <command>R3SETUP</command> - - If R3SETUP complains at this stage, edit the - template file R3SETUP used at that time - (CENTRDB.R3S (4.6B) or either - CENTRAL.R3S or - DATABASE.R3S (4.6C)). - Locate [OSUSERSIDADM_IND_ORA] or search for the - only STATUS=ERROR entry - and edit the following values: - - HOME=/home/sidadm (was empty) -STATUS=OK (had status ERROR) - - - Then you can restart R3SETUP again. - - - - OSUSERDBSID_IND_ORA during <command>R3SETUP</command> - - Possibly R3SETUP also complains at this stage. The error - here is similar to the one in phase OSUSERSIDADM_IND_ORA. - Just edit - the template file R3SETUP used at that time - (CENTRDB.R3S (4.6B) or either - CENTRAL.R3S or - DATABASE.R3S (4.6C)). - Locate [OSUSERDBSID_IND_ORA] or search for the - only STATUS=ERROR entry - and edit the following value in that section: - - STATUS=OK - - Then restart R3SETUP. - - - - <errorname>oraview.vrf FILE NOT FOUND</errorname> during &oracle; Installation - - You have not deselected &oracle; On-Line Text Viewer - before starting the installation. This is marked for installation even - though this option is currently not available for Linux. Deselect this - product inside the &oracle; installation menu and restart installation. - - - - <errorname>TEXTENV_INVALID</errorname> during <command>R3SETUP</command>, RFC or SAPgui Start - - If this error is encountered, the correct locale is - missing. &sap; Note 0171356 lists the necessary RPMs that need - be installed (e.g. saplocales-1.0-3, - saposcheck-1.0-1 for RedHat 6.1). In case - you ignored all the related errors and set the corresponding - STATUS from ERROR to OK (in CENTRDB.R3S) every time R3SETUP - complained and just restarted R3SETUP, the &sap; system will not - be properly configured and you will then not be able to - connect to the system with a - SAPgui, even though the system - can be started. Trying to connect with the old Linux - SAPgui gave the following - messages: - - Sat May 5 14:23:14 2001 -*** ERROR => no valid userarea given [trgmsgo. 0401] -Sat May 5 14:23:22 2001 -*** ERROR => ERROR NR 24 occured [trgmsgi. 0410] -*** ERROR => Error when generating text environment. [trgmsgi. 0435] -*** ERROR => function failed [trgmsgi. 0447] -*** ERROR => no socket operation allowed [trxio.c 3363] -Speicherzugriffsfehler - - This behavior is due to &sap.r3; being unable to correctly - assign a locale and also not being properly configured itself - (missing entries in some database tables). To be able to connect - to &sap;, add the following entries to file - DEFAULT.PFL (see Note 0043288): - - abap/set_etct_env_at_new_mode = 0 -install/collate/active = 0 -rscp/TCP0B = TCP0B - - Restart the &sap; system. Now you can connect to the - system, even though country-specific language settings might - not work as expected. After correcting country settings - (and providing the correct locales), these entries can be - removed from DEFAULT.PFL and the &sap; - system can be restarted. - - - - - <errorcode>ORA-00001</errorcode> - This error only happened with - &oracle; 8.1.7 on FreeBSD. - The reason was that the &oracle; database could not initialize itself - properly and crashed, leaving semaphores and shared memory on the - system. The next try to start the database then returned - ORA-00001. - - Find them with ipcs -a and remove them - with ipcrm. - - - - <errorcode>ORA-00445</errorcode> (Background Process PMON Did Not Start) - This error happened with &oracle; 8.1.7. - This error is reported if the database is started with - the usual startsap script (for example - startsap_majestix_00) as user - prdadm. - - A possible workaround is to start the database as user - oraprd instead - with svrmgrl: - - &prompt.user; svrmgrl -SVRMGR> connect internal; -SVRMGR> startup; -SVRMGR> exit - - - - - <errorcode>ORA-12546</errorcode> (Start Listener with Correct Permissions) - - Start the &oracle; listener as user - oraids with the following commands: - - &prompt.root; umask 0; lsnrctl start - - Otherwise you might get ORA-12546 as the sockets will not - have the correct permissions. See &sap; Note 0072984. - - - - <errorcode>ORA-27102</errorcode> (Out of Memory) - - This error happened whilst trying to use values for - MAXDSIZ and DFLDSIZ - greater than 1 GB (1024x1024x1024). Additionally, we got - Linux Error 12: Cannot allocate memory. - - - - [DIPGNTAB_IND_IND] during <command>R3SETUP</command> + + 進階主題 - In general, see &sap; Note 0130581 (R3SETUP step - DIPGNTAB terminates). During the - IDES-specific installation, for some reason the installation - process was not using the proper &sap; system name IDS, but - the empty string "" instead. This leads to some minor problems - with accessing directories, as the paths are generated - dynamically using SID (in this case IDS). So instead - of accessing: - - /usr/sap/IDS/SYS/... -/usr/sap/IDS/DVMGS00 - - the following paths were used: - - /usr/sap//SYS/... -/usr/sap/D00 - - To continue with the installation, we created a link and an - additional directory: - - &prompt.root; pwd -/compat/linux/usr/sap -&prompt.root; ls -l -total 4 -drwxr-xr-x 3 idsadm sapsys 512 May 5 11:20 D00 -drwxr-x--x 5 idsadm sapsys 512 May 5 11:35 IDS -lrwxr-xr-x 1 root sapsys 7 May 5 11:35 SYS -> IDS/SYS -drwxrwxr-x 2 idsadm sapsys 512 May 5 13:00 tmp -drwxrwxr-x 11 idsadm sapsys 512 May 4 14:20 trans - - We also found &sap; Notes (0029227 and 0008401) describing - this behavior. We did not encounter any of these problems with - the &sap; 4.6C installation. - + 本節描述 &linux; 二進位檔如何運作,以 Terry Lambert tlambert@primenet.com 寫給&a.chat;的電子郵件為基礎(Message ID: + <199906020108.SAA07001@usr09.primenet.com>)。 - - [RFCRSWBOINI_IND_IND] during <command>R3SETUP</command> + execution class loader - During installation of &sap; 4.6C, - this error was just the result of another error happening - earlier during installation. In this case, you have to look - through the corresponding logfiles and correct the real - problem. - - If after looking through the logfiles this error is - indeed the correct one (check the &sap; Notes), you can set - STATUS of the offending step from ERROR to OK (file - CENTRDB.R3S) and restart R3SETUP. After - installation, you have to execute the report - RSWBOINS from transaction SE38. See &sap; - Note 0162266 for additional information about phase - RFCRSWBOINI and - RFCRADDBDIF. - + &os; has an abstraction called an + execution class loader. This is a wedge into the + &man.execve.2; system call. - - [RFCRADDBDIF_IND_IND] during <command>R3SETUP</command> - Here the same restrictions apply: make sure by looking - through the logfiles, that this error is not caused by some - previous problems. - - If you can confirm that &sap; Note 0162266 applies, just - set STATUS of the offending step from ERROR to OK (file - CENTRDB.R3S) and restart R3SETUP. After - installation, you have to execute the report - RADDBDIF from transaction SE38. - + 歷史上, &unix; 載入器檢查魔術數字(通常是檔案的頭四或八個位元組)來看它是否是系統已知的二進位檔,如果是,就調用二進位檔載入器。 - - <errorcode>sigaction sig31: File size limit exceeded</errorcode> + 如果不是系統的二進位檔類型, &man.execve.2; 呼叫會回報失敗,shell會嘗試當作 shell 指令來執行。 + The assumption was a default of + whatever the current shell is. - This error occurred during start of &sap; processes - disp+work. If starting &sap; with the - startsap script, subprocesses are then started which - detach and do the dirty work of starting all other &sap; - processes. As a result, the script itself will not notice - if something goes wrong. - - To check whether the &sap; processes did start properly, - have a look at the process status with - ps ax | grep SID, which will give - you a list of all &oracle; and &sap; processes. If it looks like - some processes are missing or if you cannot connect to the &sap; system, - look at the corresponding logfiles which can be found - at /usr/sap/SID/DVEBMGSnr/work/. - The files to look at are dev_ms and - dev_disp. - - Signal 31 happens here if the amount of shared memory used by - &oracle; and &sap; exceed the one defined within the kernel configuration - file and could be resolved by using a larger value: - - # larger value for 46C production systems: -options SHMMAXPGS=393216 -# smaller value sufficient for 46B: -#options SHMMAXPGS=262144 + 後來, &man.sh.1; 做了hack來檢查頭兩字元,如果他們是 :\n,就改調用 &man.csh.1; shell 。 - + &os; 有一系列的載入器取代單一載入器,其中有with a fallback to the #! 載入器來執行 shell 解譯器或是 shell 腳本。 - - Start of <command>saposcol</command> Failed - There are some problems with the program saposcol (version 4.6D). - The &sap; system is using saposcol to collect data about the - system performance. This program is not needed to use the &sap; system, - so this problem can be considered a minor one. The older versions - (4.6B) does work, but does not collect all the data (many calls will - just return 0, for example for CPU usage). - - - - - - Advanced Topics + + ELF + - If you are curious as to how the Linux binary compatibility - works, this is the section you want to read. Most of what follows - is based heavily on an email written to &a.chat; by Terry Lambert - tlambert@primenet.com (Message ID: - <199906020108.SAA07001@usr09.primenet.com>). + + Solaris + - - How Does It Work? - execution class loader + 對於 &linux; ABI 支援, &os; 將魔術數字看待為 ELF 二進位檔。 + ELF載入器尋找專門的 brand,這是 ELF 影像的註解部份,並未存在於 SVR4/&solaris; ELF 二進位檔。 - FreeBSD has an abstraction called an execution class - loader. This is a wedge into the &man.execve.2; system - call. - - What happens is that FreeBSD has a list of loaders, instead of - a single loader with a fallback to the #! - loader for running any shell interpreters or shell scripts. - - Historically, the only loader on the &unix; platform examined - the magic number (generally the first 4 or 8 bytes of the file) to - see if it was a binary known to the system, and if so, invoked the - binary loader. - - If it was not the binary type for the system, the - &man.execve.2; call returned a failure, and the shell attempted to - start executing it as shell commands. - - The assumption was a default of whatever the current - shell is. - - Later, a hack was made for &man.sh.1; to examine the first two - characters, and if they were :\n, then it - invoked the &man.csh.1; shell instead (we believe SCO first made - this hack). - - What FreeBSD does now is go through a list of loaders, with a - generic #! loader that knows about interpreters - as the characters which follow to the next whitespace next to - last, followed by a fallback to - /bin/sh. - ELF - - For the Linux ABI support, FreeBSD sees the magic number as an - ELF binary (it makes no distinction between FreeBSD, &solaris;, - Linux, or any other OS which has an ELF image type, at this - point). - Solaris - - The ELF loader looks for a specialized - brand, which is a comment section in the ELF - image, and which is not present on SVR4/&solaris; ELF - binaries. - - For Linux binaries to function, they must be - branded as type Linux - from &man.brandelf.1;: + For &linux; binaries to function, they must be + branded as type Linux + using &man.brandelf.1;: - &prompt.root; brandelf -t Linux file + &prompt.root; brandelf -t Linux file - When this is done, the ELF loader will see the - Linux brand on the file. - - ELF - branding - + + ELF + branding + - When the ELF loader sees the Linux brand, - the loader replaces a pointer in the proc - structure. All system calls are indexed through this pointer (in - a traditional &unix; system, this would be the - sysent[] structure array, containing the system - calls). In addition, the process is flagged for special handling of - the trap vector for the signal trampoline code, and several other - (minor) fix-ups that are handled by the Linux kernel - module. - - The Linux system call vector contains, among other things, a - list of sysent[] entries whose addresses reside - in the kernel module. - - When a system call is called by the Linux binary, the trap - code dereferences the system call function pointer off the - proc structure, and gets the Linux, not the - FreeBSD, system call entry points. - - In addition, the Linux mode dynamically - reroots lookups; this is, in effect, what the - option to file system mounts - (not the unionfs file system type!) does. First, an attempt - is made to lookup the file in the - /compat/linux/original-path - directory, then only if that fails, the - lookup is done in the - /original-path - directory. This makes sure that binaries that require other - binaries can run (e.g., the Linux toolchain can all run under - Linux ABI support). It also means that the Linux binaries can - load and execute FreeBSD binaries, if there are no corresponding - Linux binaries present, and that you could place a &man.uname.1; - command in the /compat/linux directory tree - to ensure that the Linux binaries could not tell they were not - running on Linux. - - In effect, there is a Linux kernel in the FreeBSD kernel; the - various underlying functions that implement all of the services - provided by the kernel are identical to both the FreeBSD system - call table entries, and the Linux system call table entries: file - system operations, virtual memory operations, signal delivery, - System V IPC, etc… The only difference is that FreeBSD - binaries get the FreeBSD glue functions, and - Linux binaries get the Linux glue functions - (most older OS's only had their own glue - functions: addresses of functions in a static global - sysent[] structure array, instead of addresses - of functions dereferenced off a dynamically initialized pointer in - the proc structure of the process making the - call). - - Which one is the native FreeBSD ABI? It does not matter. - Basically the only difference is that (currently; this could - easily be changed in a future release, and probably will be after - this) the FreeBSD glue functions are - statically linked into the kernel, and the Linux glue functions - can be statically linked, or they can be accessed via a kernel - module. - - Yeah, but is this really emulation? No. It is an ABI - implementation, not an emulation. There is no emulator (or - simulator, to cut off the next question) involved. - - So why is it sometimes called Linux emulation? - To make it hard to sell FreeBSD! Really, it - is because the historical implementation was done at a time when - there was really no word other than that to describe what was - going on; saying that FreeBSD ran Linux binaries was not true, if - you did not compile the code in or load a module, and there needed - to be a word to describe what was being loaded—hence - the Linux emulator. - + When the ELF loader sees the Linux + brand, the loader replaces a pointer in the + proc structure. All system calls are indexed + through this pointer. In addition, the process is flagged for + special handling of the trap vector for the signal trampoline + code, and several other (minor) fix-ups that are handled by the + &linux; kernel module. + + The &linux; system call vector contains, among other things, + a list of sysent[] entries whose addresses + reside in the kernel module. + + When a system call is called by the &linux; binary, the trap + code dereferences the system call function pointer off the + proc structure, and gets the &linux;, not the + &os;, system call entry points. + + &linux; mode dynamically reroots + lookups. This is, in effect, equivalent to the + option to file system mounts. First, an + attempt is made to lookup the file in /compat/linux/original-path. + If that fails, the lookup is done in /original-path. + This makes sure that binaries that require other binaries can + run. For example, the &linux; toolchain can all run under + &linux; ABI support. It also means that the + &linux; binaries can load and execute &os; binaries, if there + are no corresponding &linux; binaries present, and that a + &man.uname.1; command can be placed in the + /compat/linux directory tree to ensure that + the &linux; binaries can not tell they are not running on + &linux;. + + In effect, there is a &linux; kernel in the &os; kernel. + The various underlying functions that implement all of the + services provided by the kernel are identical to both the &os; + system call table entries, and the &linux; system call table + entries: file system operations, virtual memory operations, + signal delivery, and System V IPC. The only difference is that + &os; binaries get the &os; glue functions, + and &linux; binaries get the &linux; glue + functions. The &os; glue functions are + statically linked into the kernel, and the &linux; + glue functions can be statically linked, or + they can be accessed via a kernel module. + + Technically, this is not really emulation, it is an + ABI implementation. It is sometimes called + &linux; emulation because the implementation was + done at a time when there was no other word to describe what was + going on. Saying that &os; ran &linux; binaries was not true, + since the code was not compiled in.