YellowDogLinux on PowerMacG5

Source: Internet
Author: User
Title: YellowDogLinux on PowerMacG5. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
   Install Yellow Dog Linux
First, you must understand that you cannot guide G5 through the publicly available YDL 3.0.1 ISO. This is because version 3.0.1 of "hybrid" for G5 is still in the testing phase; When productized, they will be published on public sites. To obtain a G5-compatible 32-bit ydl iso, you must subscribe "YDL.net Enhanced" for membership (see references ).
  
After the subscription, be careful to download the correct ISO. The common ISO number is 3.0.1, which is located in the/enhanced/iso/FTP directory. These are not what you want. The G5 ISO used in the experiment is also numbered 3.0.1, but the download directory is deeper, In the/enhanced/iso/PowerMacG5/directory. Since they are still in the test phase, the exact file date may change; the names I use are *-20040204-*. iso.
  
After the test, the 32-bit YDL compatible with G5 will be upgraded to version 4.0 and will be available without the need for membership. However, a 64-bit Y-HPC will only be available to members of "YDL.net Pro" (not Enhanced. The only other way to get 64-bit kernels from Terra Soft is to wait for them to be available from TSS online storage or buy pre-configured kernels, used on the G5 system pre-built by Terra Soft. This is done according to the buyer's requirements and requires additional fees. Therefore, if you need to do so, you need to specify it.
  
In any case, other PPC Linux publishers-such as Mandrake, Debian, Gentoo, and SUSE-are also preparing their own Linux systems that can be directly used for G5. Of course, Gentoo is the only publisher I know that is actively developing the 64-bit G5 kernel. Other publishers are currently working on the 32-bit version. However, from working features to the Macintosh-related HowTo, most of the content covered in this article should also apply to all future releases of these expectations.
  
It is worth noting that, especially if you are familiar with Linux on x86, there is no good way to re-allocate existing HFS + partitions without loss. Of course, this is true for any Linux release version on Mac that you want to install, because Power Mac G5 is originally divided into a large partition. You will need to delete and reinstall OSX to configure the dual-boot system. For dedicated servers, you may only need one OS, but for most other developers, multi-boot configuration is practical.
  
The simplest way to create a dual-boot or multi-boot Power Mac G5 system is to reinstall OSX through the installation media attached to the random device. At the beginning of OSX installation, select "Disk Utility" from the menu to create a smaller HFS + partition and leave the remaining parts in free space. On the hard drive of my 160 GB test system, I allocated 30 GB for OSX (if necessary, I can create more HFS + Partitions at any time ).
  
After reinstalling and setting aside some free disk space, you only need to add the ydl cd compatible with G5 as described above. As with all Macintosh, press the "c" key during reboot to boot from the CD instead of from the hard drive. Yellow Dog's Rad Hat-based Anaconda installer is very friendly. All devices except the sound card are automatically recognized by the installer-and even include the exact model and performance of my monitor that fails to be detected by OSX. My DHCP router and Ethernet are seamlessly connected. There is a small defect, that is, the monitor frequency is 60Hz when the installer is running, which will produce disturbing jitter under the fluorescent lamp. However, after the installation is complete, Yellow Dog uses 70 + Hz (and configurable) beneficial to visual health ). Note: You should first reinstall OSX and then install Linux. If you install it in another way, it will lead to more work.
  
During installation, YDL executes the user-friendly tool "Disk Druid" to describe the partition options for you. Log-containing ext3 is the preferred File System (which is also used by me ). If you select "Automatic", Disk Druid declares that all free space is used by Linux; I prefer to manually configure another 30 GB ext3 partition (and set a default swap partition at the end of the disk ). In this way, we have set aside about 100 GB space. I can use any file system I need to install another OS or data partition. Later, during the installation process, Yellow Dog installs the Boot manager ylow T, which is almost the same as lilo on the x86 system (including A/etc/Yaboot. conf/configuration file ).
  
After selecting the package you want to install, You may select a common option, for example, "Desktop", "Server", or "Developer Workstation"-the installation process is complete and then rebooted to the Yaboot Boot manager. If you select "Linux" instead of "OSX" during the boot process, Yellow Dog displays all the text information that Linux users are familiar with about drive and background program loading. After about 40 seconds (on a dual-1.8GHz G5 machine), you will come to the welcome screen for Yellow Dog, where you can log on as a user, reboot, select a desktop environment, and more. It is worth mentioning that it takes only 15 seconds for OSX to boot on the same machine, which is surprising. KDE is the default environment of YDL, but Gnome is also included in the installation CD (and you can compile any Windows Manager that you like through source files ).
  
   G5 Linux
YDL is very similar to other modern Linux releases. It comes with GCC (the current G5 test version is v3.3.3) and the latest version of Python, Perl, Ruby and other programming languages. The KDE Start Menu contains office software in a logical hierarchy, such as OpenOffice, GIMP, Mozilla, KDevelop, and other development environments. You can use their original default mode and interface configuration, or you can use KDE Control Center or various right-click methods to change their behavior as you wish.
  
Let me introduce some configuration specific to Macintosh and Power Mac G5, which may be unfamiliar to x86 Linux users. First, you should consider making your osx hfs + partition data readable. In my opinion, the driver for processing logs in HFS + is still in the experiment phase, so you 'd better set HFS + to read-only. To access HFS +, perform the following steps (you will need to log on as root or use su ):
  
Listing 1. mount an HFS + partition under YDL
  
% Mkdir/mnt/osx
% Modprobe hfsplus
% Parted/dev/sda # press "p" for partition list
% Mount/dev/sda3/mnt/osx-thfsplus
% Ls/mnt/osx
  
Run the parted command to view the Partition Number and file system. Observe the tools to check which HFS + Partitions you have. If you want to use Konqueror and KDE desktops to navigate files, you may need to drag/mnt/osx from the Konqueror window to the desktop.
  
Unlike x86 systems, there is no "eject" button on the macdeskshes CD drive. In OSX, you can use a special key on the keyboard to open the drive. In YDL, You need to execute the command eject/dev/cdrom in the command prompt (or attach this action to an icon ). After you insert a new CD into the drive, you need to run mount/dev/cdrom or configure it as automatic as appropriate.
  
Unfortunately, Terra Soft incorporates a hybrid 2.6.4 kernel for the beta version to be available on G5, but this kernel cannot be used with Mac-on-Linux (MoL. Those who are new to Linux should know that, in the case of a similar situation, downloading and re-compiling the latest source code of abnormal applications can usually solve the problem. However, this time does not work, so before we expect MoL to be used for G5, we only need to wait for the Mac-on-Linux project to release a new module.
  
Upgrade 32-bit YDL to 64-bit Y-HPC
According to Terra Soft, once productized, 64-bit installation will become very simple. Before that, if you want to try a 64-bit kernel before the official release of the Y-HPC, first you need to install 32-bit YDL like me. Then, go to the Yellow Dog Linux Y-HPC page (see references) and download the vmlinux * and System * files to/boot /. In that directory, I run:
  
Listing 2. unpackage 64-bit Linux Kernel
  
% Gunzip vmlinux-2.6.1-1.64.ydl.1.1280.gz
% Gunzip System.map-2.6.1-1.64.ydl.1.1280.gz
Vmlinux-2.6.1-1.64.ydl.1.1280 % chmod u + x
  
I also got the kernel module, downloaded to/root/, and then run:
  
Listing 3. unpackage 64-bit kernel module
  
% Bzip2-d/root/modules-2.6.1-1.64.ydl.1.1280.tar.bz2
% Cd/
% Tar xvf/root/modules-2.6.1-1.64.ydl.1.1280.tar
  
The last step is to create many files in the/lib/modules/2.6.1-1.64.ydl.1.1280/directory. The next step is to add the 64-bit kernel to the Boot manager. First, edit/etc/yunct. conf and add:
  
Listing 4. Adding a 64-bit Y-HPC kernel to ymeant
  
Image =/boot/vmlinux-2.6.1-1.64.ydl.1.1280
Label = linux-64bit
Root =/dev/sda4
Read-only
Append = "hda = ide-cd"
  
Then run ybin (as root) so that you can select the kernel during the next restart. As you can see, with the 64-bit kernel, the performance is minimized; however, with the 64-bit kernel selected, You can compile a 64-bit application that may benefit from 64-bit-ness.
  
   GCC options and cross-Compilation
I ran some LMBench benchmarking tests using different kernel versions and compilation options (I will summarize it at the end of this Article ). Although this benchmark test was not significantly affected by the options I tried, LMBench's source code still provides a useful project that can be used to test compilation options. For example, in a configuration using a 64-bit kernel, before performing the common make steps, I entered the following content to configure the compiler:
  
% Export CPPFLAGS = '-mcpu = 970-mtune = 100'
  
In the document "About Compilers with VMX Support" (see references), you can find a practical summary of the main options of the PowerPC 970 compiler. This document references the hybrid YDL and IBM eServer Based on PowerPC 970.™JS20 BladeCenter™GCC 3.3.3 attached to the machine. You can compare the compilation options available in Linux and Darwin (Mac OSX)-most of them are similar, but there are some differences.
  
In addition, the entire POWER family architecture is designed to support cross-Compilation of different targets and compilation of general instruction bases. It is extremely fascinating that it is possible to develop an application on Apple Power Mac G5 and
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.