Вы находитесь на странице: 1из 14

Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

root@soltest:~# cat /etc/release


Oracle Solaris 11.2 X86
Copyright (c) 1983, 2014, Oracle and/or its affiliates.
All rights reserved.
Assembled 23 June 2014
root@soltest:~#

root@soltest:~# zoneadm list -icv


ID NAME STATUS PATH BRAND IP
0 global running / solaris shared

1 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

root@soltest:~# zpool create dbzone c2t1d0


root@soltest:~# zpool status
pool: dbzone
state: ONLINE
scan: none requested
config:

NAME STATE READ WRITE CKSUM


dbzone ONLINE 0 0 0
c2t1d0 ONLINE 0 0 0

errors: No known data errors

pool: rpool
state: ONLINE
scan: none requested
config:

NAME STATE READ WRITE CKSUM


rpool ONLINE 0 0 0
c2t0d0s1 ONLINE 0 0 0

errors: No known data errors


root@soltest:~#

root@soltest:~# df -h /dbzone
Filesystem Size Used Available Capacity Mounted on
dbzone 49G 31K 49G 1% /dbzone
root@soltest:~#

root@soltest:~# zfs create dbzone/dbnode1


root@soltest:~# df -h /dbzone/
Filesystem Size Used Available Capacity Mounted on
dbzone 49G 32K 49G 1% /dbzone
root@soltest:~# df -h /dbzone/dbnode1/
Filesystem Size Used Available Capacity Mounted on
dbzone/dbnode1 49G 31K 49G 1% /dbzone/dbnode1
root@soltest:~#

root@soltest:~# zonecfg -z dbnode1


Use 'create' to begin configuring a new zone.
zonecfg:dbnode1> create
create: Using system default template 'SYSdefault'
zonecfg:dbnode1> set zonepath=/dbzone/dbnode1
--> Location of non-globalzone
zonecfg:dbnode1> set autoboot=true
zonecfg:dbnode1> set bootargs="-m verbose"
zonecfg:dbnode1> verify
zonecfg:dbnode1> commit
zonecfg:dbnode1> exit

root@soltest:~# zoneadm list -icv


ID NAME STATUS PATH BRAND IP
0 global running / solaris shared
- dbnode1 configured /dbzone/dbnode1 solaris excl
root@soltest:~#

2 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

root@soltest:~# pkg publisher


PUBLISHER TYPE STATUS P LOCATION
solaris origin online F file:///IPS/

root@soltest:~# zoneadm -z dbnode1 install


/dbzone/dbnode1 must not be group readable.
/dbzone/dbnode1 must not be group executable.
/dbzone/dbnode1 must not be world readable.
/dbzone/dbnode1 must not be world executable.
changing zonepath permissions to 0700.
Progress being logged to /var/log/zones
/zoneadm.20150505T110020Z.dbnode1.install
Image: Preparing at /dbzone/dbnode1/root.

Install Log: /system/volatile/install.2559/install_log


AI Manifest: /tmp/manifest.xml.Z4ay.e
SC Profile: /usr/share/auto_install/sc_profiles
/enable_sci.xml
Zonename: dbnode1
Installation: Starting ...

Creating IPS image


Startup linked: 1/1 done
Installing packages from:
solaris
origin: http://localhost:1008/solaris
/1b7ace04cda8d7daded2712a9ad862bbff5d188a/
DOWNLOAD PKGS FILES XFER (MB) SPEED
Completed 281/281 53255/53255 352.0/352.0 355k/s

PHASE ITEMS
Installing new actions 71042/71042
Updating package state database Done
Updating package cache 0/0
Updating image state Done
Creating fast lookup database Done
Updating package cache 1/1
Installation: Succeeded

Note: Man pages can be obtained by installing pkg:/system


/manual

done.

Done: Installation completed in 1345.180 seconds.


Next Steps: Boot the zone, then log into the zone console
(zlogin -C)

to complete the configuration process.

Log saved in non-global zone as /dbzone/dbnode1/root/var


/log/zones/zoneadm.20150505T110020Z.dbnode1.install

root@soltest:~# zfs list | grep zone


dbzone 675M 48.3G 32K /dbzone
dbzone/dbnode1 675M 48.3G 32K /dbzone/dbnode1
dbzone/dbnode1/rpool 675M 48.3G 31K /rpool
dbzone/dbnode1/rpool/ROOT 675M 48.3G 31K legacy
dbzone/dbnode1/rpool/ROOT/solaris 675M 48.3G 635M /dbzone
/dbnode1/root

3 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

dbzone/dbnode1/rpool/ROOT/solaris/var 39.7M 48.3G 38.8M


/dbzone/dbnode1/root/var
dbzone/dbnode1/rpool/VARSHARE 31K 48.3G 31K /var/share
dbzone/dbnode1/rpool/export 62K 48.3G 31K /export
dbzone/dbnode1/rpool/export/home 31K 48.3G 31K /export
/home
rpool/VARSHARE/zones 31K 54.3G 31K /system/zones
root@soltest:~#

root@soltest:~# zoneadm list -icv


ID NAME STATUS PATH BRAND IP
0 global running / solaris shared
- dbnode1 installed /dbzone/dbnode1 solaris excl
root@soltest:~#

root@soltest:~# zoneadm -z dbnode1 boot

Then press ESC-2 to continue with the Installation of zone

4 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

5 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

6 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

7 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

8 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

9 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

C profile successfully generated as:


/etc/svc/profile/sysconfig/sysconfig-20150505-114413
/sc_profile.xml

Exiting System Configuration Tool. Log is available at:


/system/volatile/sysconfig/sysconfig.log.4200
[ system/manifest-import:default starting (service
manifest import) ]
[ system/timezone:default starting (Timezone Reload) ]
[ system/coreadm:default starting (system-wide core file
configuration) ]
[ system/config-user:default starting (configure root and
user account) ]

10 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

[ network/install:default starting (physical network


interfaces install) ]
[ network/physical:upgrade starting ]
[ network/location:upgrade starting ]
Warning: Unable to verify add of static route on net0/v4
Error code = 146
[ network/physical:default starting (physical network
interface configuration) ]
[ network/location:default starting (network interface
configuration) ]
[ system/identity:node starting (system identity
(nodename)) ]
Hostname: dbnode1
[ system/name-service/switch:default starting (Local
files based naming services) ]
[ network/ipsec/policy:default starting (IPsec policy
initialization) ]
[ system/identity:domain starting (system identity
(domainname)) ]
[ system/name-service/cache:default starting (name
service cache) ]
[ milestone/network:default starting (Network milestone) ]
[ network/iptun:default starting (IP tunnel
configuration) ]
[ network/initial:default starting (initial network
services) ]
[ network/dns/client:default starting (DNS resolver) ]
[ application/pkg/zones-proxy-client:default starting
(Zones Proxy Client) ]
[ milestone/single-user:default starting (single-user
milestone) ]
[ network/routing-setup:default starting (Initial routing-
related configuration.) ]
[ milestone/name-services:default starting (name services
milestone) ]
[ system/filesystem/local:default starting (local file
system mounts) ]
[ network/service:default starting (layered network
services) ]
[ network/nfs/fedfs-client:default starting (FedFS
client) ]
[ network/netmask:default starting (Reset the netmask and
broadcast address) ]
[ system/auditset:default starting (Set non-/attributable
audit flags
in the kernel context.) ]
[ system/cron:default starting (clock daemon (cron)) ]
[ application/pkg/repositories-setup:default starting
(IPS rpool/VARSHARE/pkg creation) ]
[ network/inetd-upgrade:default starting (inetd-upgrade) ]
[ network/shares:default starting (Share Group) ]
[ application/security/compliance:default starting
(compliance guide) ]
[ system/filesystem/ufs/quota:default starting (UFS quota
support) ]
[ network/shares/group:default starting (Share Group
(upgrade only)) ]
[ network/routing/ndp:default starting (in.ndpd IPv6
neighbour discovery daemon) ]
[ network/rpc/bind:default starting (RPC bindings) ]
May 5 11:56:37 svc.startd[3966]: Could not log for
svc:/network/inetd:default: fprintf() failed with I/O
error.
[ system/fmd:default starting (Solaris Fault Manager) ]
May 5 11:56:38 svc.startd[3966]: Could not log for
svc:/system/fmd:default: fprintf() failed with Error 0.
[ system/filesystem/autofs:default starting (automounter)

11 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

]
May 5 11:56:38 svc.startd[3966]: Could not log for
svc:/system/filesystem/autofs:default: fprintf() failed
with Error 0.
[ network/ssh:default starting (SSH server) ]
May 5 11:56:38 svc.startd[3966]: Could not log for
svc:/network/ssh:default: fprintf() failed with Error 0.
[ milestone/self-assembly-complete:default starting
(Updates configured milestone) ]
May 5 11:56:40 svc.startd[3966]: Could not log for
svc:/milestone/self-assembly-complete:default: fprintf()
failed with Error 0.
[ system/system-log:default starting (system log) ]
May 5 11:56:40 svc.startd[3966]: Could not log for
svc:/system/system-log:default: fprintf() failed with
Error 0.
[ network/smtp:sendmail starting (sendmail SMTP mail
transfer agent) ]
[ network/sendmail-client:default starting (sendmail SMTP
client queue runner) ]
[ system/auditd:default starting (Solaris audit daemon) ]
[ system/console-login:default starting (Console login) ]

dbnode1 console login: root


Password:
May 5 11:58:02 dbnode1 login: ROOT LOGIN /dev/console
Oracle Corporation SunOS 5.11 11.2 August 2014
root@dbnode1:~# root@dbnode1:~# hostname
dbnode1
root@dbnode1:~# ping dbnode1
dbnode1 is alive

root@soltest:~# zoneadm list -icv


ID NAME STATUS PATH BRAND IP
0 global running / solaris shared
1 dbnode1 running /dbzone/dbnode1 solaris excl
root@soltest:~#
root@dbnode1:~# dladm show-link
LINK CLASS MTU STATE OVER
net0 vnic 1500 up ?
<---- Virtual NIC
root@dbnode1:~# uname -a
SunOS dbnode1 5.11 11.2 i86pc i386 i86pc <----- Releasse
root@dbnode1:~# ipadm show-addr
ADDROBJ TYPE STATE ADDR
lo0/v4 static ok 127.0.0.1/8
net0/v4 static ok 192.168.1.48/24
lo0/v6 static ok ::1/128
net0/v6 addrconf ok fe80::8:20ff:fe1c:4161/10
root@dbnode1:~#

root@soltest:~# zonecfg -z dbnode1 info


zonename: dbnode1
zonepath: /dbzone/dbnode1
brand: solaris
autoboot: true
autoshutdown: shutdown
bootargs: -m verbose
file-mac-profile:
pool:

12 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

limitpriv:
scheduling-class:
ip-type: exclusive
hostid:
tenant:
fs-allowed:
anet:
linkname: net0
lower-link: auto
allowed-address not specified
configure-allowed-address: true
defrouter not specified
allowed-dhcp-cids not specified
link-protection: mac-nospoof
mac-address: auto
auto-mac-address: 2:8:20:1c:41:61
mac-prefix not specified
mac-slot not specified
vlan-id not specified
priority not specified
rxrings not specified
txrings not specified
mtu not specified
maxbw not specified
rxfanout not specified
vsi-typeid not specified
vsi-vers not specified
vsi-mgrid not specified
etsbw-lcl not specified
cos not specified
pkey not specified
linkmode not specified
evs not specified
vport not specified
root@soltest:~#

root@soltest:~# ping dbnode1


ping: unknown host dbnode1
root@soltest:~#

root@soltest:~# cat /etc/hosts


#
# Copyright 2009 Sun Microsystems, Inc. All rights
reserved.
# Use is subject to license terms.
#
# Internet host table
#
::1 soltest localhost
127.0.0.1 localhost loghost
192.168.1.49 soltest
192.168.1.48 dbnode1 <---- Entry updated
root@soltest:~#

root@soltest:~# ping dbnode1


dbnode1 is alive
root@soltest:~#

root@soltest:~# ssh oratest@dbnode1


Password:
Last login: Tue May 5 12:31:36 2015 from soltest

13 of 14 5/28/2015 4:12 PM
Create zone in Oracle Solaris 11.2 - Oracle - Oracle - Toad World http://www.toadworld.com/platforms/oracle/b/weblog/archive/2015/05...

Could not chdir to home directory /export/home/oratest:


No such file or directory
Oracle Corporation SunOS 5.11 11.2 August 2014
-bash-4.1$ hostname
dbnode1
-bash-4.1$

14 of 14 5/28/2015 4:12 PM

Вам также может понравиться