Solaris 10 x86 installation memo

xiaoxiao2021-03-05  23

Solaris 10 x86 installation memo

Author: Badcoffee

Email: blog.oliver@gmail.com

April 2005

Original article: http://blog.9cbs.net/yayong

Copyright: Please be sure to indicate the original source, author information and this statement in hyperlinks.

HW:

CPU AMD Athlon 2000

MEM 512M

Disk 120g

NIC motherboard integrated VIA network card

SW:

OS Solaris 10 x86 GA

App VPN3000 Client comes from two open source projects, respectively:

- Virtual tunnel from http://vtun.sourceforge.net/

- vpnc from http://www.minix-ag.uni-kl.de/~massar/vpnc/

2. Installation of Solaris 10 x86

There are many articles about Solaris installation, and let's take a delay here.

2.1 About hard disk partition

For IDE hard drive, you need to install on a separate primary partition

In addition, in order to exchange data with other OS (WinXP, Linux) on the same machine, it is recommended to re-WinXP on the hard disk to leave a FAT32 logical drive.

The new partition type of Solaris 10 is Solaris2, and its primary partition number is no longer conflict with Linux SWAP, so it doesn't worry that it will affect Linux.

2.2 About hardware drive

Solaris 10 x86 Support for X86 hardware has been greatly enhanced, and only the NICs on my machine are not detected during the installation process.

For hardware that cannot be identified correctly, you need to find a related Driver on the HCL of the SUN official website according to the type of hardware.

Fortunately, the VIA motherboard integrated NIC has already developed Driver, which can be found and downloaded in the HCL:

http://www.sun.com/bigadmin/hcl/

2.3 About XWindow

It is recommended to select xorg as the default xserver and select JDS as the default desktop.

2.4 Mount about FAT32

After the installation is complete, add the setting of the FAT32 logical drive under the / etc / vfstab to the automatic Mount WinXP

/ DEV / DSK / C0D0P0: C - / WinXP PCFS 2 YES -

3. Environment settings and application software installation

You can change the default shell of root to BASH

# vi / etc / passwd

root: x: 0: 0: Super-user: /: / usr / bin / bash

Solaris has brought some open source software, such as Mozilla, GCC

If you need to use, you'd better add / usr / sfw / bin to the environment variable path.

This is my / etc / profile added setting:

Path = $ PATH: / USR / SFW / BIN: / USR / CSW / BIN: $ PATH;

Export Path

Editor = / OPT / SFW / BIN / VIM

Export Editor

PS1 = "/ h: / w #"

Export PS1

In addition, there is also the following ways to obtain various open source community software

1. Solaris's companies CD

2.

Www.sunfreeware.com has included some most common open source software

3.

Www.blastwave.org The open source software here is the most complete, strongly recommended

About the Solaris environment and application software, you can also refer to my following articles:

Development Environment Installation and Settings on Solaris

Solaris Do 10 software for Desktop

Using Subversion and Viewcvs on Solaris 10

After installing all the software in the previous article, set the work environment of the BASH:

Cat /.bashrc

Term = DTTERMEXPORT TERM

Alias ​​Ls = '/ usr / local / bin / ls --color'

Alias ​​Vi = '/ OPT / SFW / BIN / VIM'

PS1 = "/ h: / w #"

Export PS1

In this way, the grammar of LS and VIM with color is highlighted, and Firefox, Thounderbird, MSN, QQ, Office, and media play are all have.

4. ADSL settings

4.1 Solaris DNS client settings

#Cp /etc/nsswitch.dns /etc/nsswitch.conf

This is my /etc/resolv.conf configuration file content:

Nameserver 202.106.46.151

4.2 ISP profile

#Cat / etc / ppp / peers / dialconf

SPPPTUN

Plugin Pppoe.so

Connect "/ usr / lib / inet / pppoec rh0" # My network card interface is RH0

Persist

User "* adslname" # Netcom's Account Name is always the username starting with the *, assumes that I is * ADSLNAME

NOAUTH # do not Authenticate The ISP's Identity (Client)

NOIPDEFAULT # Assume NO IP Address; Get IT from ISP

Defaultroute # install default route; ISP is Internet Gateway

Updetach # log errors and connect string to invoker

NOCCP

Novj

NOACComp

NOPComp

4.3 User Verification Files

#Cat / etc / ppp / chap-secrets

"* ADSLNAME" * "111111"

Note: "* ADSLNAME", *, "111111" is used between [Tab] instead of space, here, the password is 111111

If your ISP needs to set / etc / ppp / chat- seconds, the content format is similar

4.4 Creating a Dial Shell File

#CAT / OPT / ADSL

SPPPTUN PLUMB PPPOED RH0

SPPPTUN PLUMB PPPOE RH0

SPPPTUN Query

/ usr / bin / pppd call dialconf

Echo "Link SuccessFully ..."

4.5 dial test

# / OPT / ADSL

RH0: PPPOED

RH0: PPPoe

RH0: PPPOED

RH0: PPPoe

SERIAL Connection Establish.

Using Interface SPP0

Connect: SPP0 <-> / dev / sppptun

Remote Message: Welcome to Use

Quidway Router, Huawei Tech. ^ M ^ J # Oh, it turned out to be Huawei router

Local IP Address 221.216.249.95

Remote IP Address 61.51.112.1

Link SuccessFully ...

#ifconfig -a

LO0: Flags = 2001000849 MTU 8232 Index 1Inet 127.0.0.1 Netmask FF000000

RH0: Flags = 1000843 MTU 1500 INDEX 2

INET 192.168.80.1 Netmask fffff00 Broadcast 192.168.80.255

Ether 0: C: 6E: 8B: D2: 94

SPPP0: Flags = 10010008d1 MTU 1492 INDEX 3

INET 221.216.249.95 -> 61.51.112.1 Netmask fffff00

The red part is the interface established by ADSL

#Ping 216.239.53.9

216.239.53.9 IS Alive

#Ping www.sina.com.cn

Www.sina.com.cn is alive

4.6 Disconnect ADSL

#pkill PPPD

5. Setting of VPN3000

Compiling the process

5.1 Configuration of VPN gateway parameters

#cat default.conf

Interface name tun0

IPsec Gateway 211.103.22.21 # This is the address of the VPN gateway

IPsec ID VPN3000 # Here is your VPN Group ID

IPsec Secret VPN3000 # Here is your VPN Group Password

Xauth Username Loginname # Here is your loginname

Ike DH Group DH2

Perfect Forward Secrecy NOPFS

5.2 Settings of the connection script

#cat vpnc-connectc

#! / usr / bin / ksh

# * VPNGATEWAY - VPN GATEWAY Address (Always Present)

# * TDEV - Tunnel Device (Always Present)

# * INTERNAL_IP4_ADDRESS - Address (Always Present)

# * INTERNAL_IP4_NETMASK - NETMASK (OFTEN UNSET)

# * INTERNAL_IP4_DNS - List of DNS Serverss

# * INTERNAL_IP4_NBNS - List of Wins Servers

# * Cisco_Def_domain - Default Domain Name

# * Cisco_banner - Banner from Server

DEFR = / var / run / vpnc / defaultroute

vpngateway = / var / run / vpnc / vpngateway

PID = / var / run / vPNC / PID

Export ld_library_path = "` DIRNAME $ 0`: $ ld_library_path

IF [-z "$ VPNGATEWAY"]; then

IF [-x "` which vpnc` "]; then

VPNC = "` Which vpnc` "

Elif [-x / usr / local / sbin / vpnc]; then

VPNC = / usr / sbin / vpncelif [-x / usr / sbin / vpnc]; then

VPNC = / usr / sbin / vpnc

Elif [-x `Dirname $ 0` / vpnc]; then

VPNC = "` DIRNAME $ 0` "/ VPNC

ECHO $ ​​VPNC

Else

Echo no vpnc daemon found, Aborting ...

EXIT 1

Fi

For i in "$ GATEWAY" "$ DEFR" "$ PID"; do

Mkdir -P "` DIRNAME $ I` "

DONE

PID = "` cat "$ PID" 2> / dev / null` "

IF [$ PID "]; then

IF KILL-0 "$ PID"> / dev / null 2> & 1; then

echo "VPNC Found Running (PID: $ PID, PIDFILE: $ PID)"

EXIT 1

Fi

Fi

Exec "$ VPNC" --udp --Pid-file "$ pid" --script "$ 0" "$ @" || EXIT 1 # Note --UDP specifies that the VPN is UDP

Fi

IFCONFIG $ TUNDEV INET $ INTERNAL_IP4_ADDRESS /

Destination $ INTERNAL_IP4_ADDRESS /

Netmask 255.255.255.255 MTU 1412 UP

Current_gateway = `NetStat -Rn | Grep ^ default | awk '{print $ 2}'`

Echo $ current_gateway> "$ defr"

Echo "$ VPNGATEWAY"> "$ VPNGATEWAY"

Route Add $ CURRENT_GATEWAY

ROUTE DELETE Default $ CURRENT_GATEWAY

Route Add Default $ INTERNAL_IP4_ADDRESS -INTERFACE

# Takes Care of DNS

IF [-f "/etc/resolv.conf"]; then

mv /etc/resolv.conf /etc/resolv.conf.saved-by-vpnc

Fi

Echo "# vpnc generated file"> /etc/resolv.conf

Echo "Search $ Cisco_DEF_DOMAIN" >> /etc/resolv.conf

Echo "$ INTERNAL_IP4_DNS" /

| awk '{for (i = 1; i <= nf; i )

Printf ("Nameserver% S / N", $ I)} '>> /etc/resolv.conf

EXIT 0

5.2 connection test

./VPNC-CONNECT Default.conf

# ifconfig -a

LO0: Flags = 2001000849 MTU 8232 INDEX 1

INET 127.0.0.1 Netmask FF000000RH0: Flags = 1000843 MTU 1500 INDEX 2

INET 192.168.80.1 Netmask fffff00 Broadcast 192.168.80.255

Ether 0: C: 6E: 8B: D2: 94

SPPP0: Flags = 10010008d1 MTU 1492 INDEX 3

INET 221.216.249.95 -> 61.51.112.1 Netmask fffff00

Tun0: flags = 10010008d1 MTU 1412 INDEX 4

INET 10.13.22.19 -> 10.13.22.19 Netmask ffffffffff

The red part is the interface established by VPN

5.3 Disconnect connection

./vpnc-disconnect

Related documents:

Development Environment Installation and Settings on Solaris

Solaris Do 10 software for Desktop

Using Subversion and Viewcvs on Solaris 10

Concerned: 10 new changes in Solaris 10

All of my Solaris articles list

转载请注明原文地址:https://www.9cbs.com/read-37734.html

New Post(0)