创建Solaris区域

发布于 2024-07-17 01:21:34 字数 198 浏览 4 评论 0 原文

对于这些部分:

zonecfg:[区域名称]:net> 设置地址= zonecfg:[区域名称]:net> 设置物理=

我怎么知道我应该设置什么样的值?

我正在使用一台打开solaris 的vmware 机器,当前正在设置一个区域。

我希望能够进入该区域。

谢谢

For these part :

zonecfg:[zone name]:net> set address=
zonecfg:[zone name]:net> set physical=

How do i know what kind of values i should set?

I am using a vmware machine open solaris and current setting up a zone.

I want to be able to putty in to that zone.

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

無心 2024-07-24 01:21:34

由于您想要从外部通过 SSH 进入区域,因此它需要在与全局区域相同的网络上拥有自己的 IP 地址。 因此,要么在同一网络中找到一个空闲地址,要么要求网络管理员分配一个地址 - 无论您通常做什么。

对于“物理”设置; 这里(我认为)是最简单的情况:如果您为虚拟机分配了一个虚拟网络接口,则使用该接口进行“物理”设置

因此,在全局区域中,

/usr/sbin/ifconfig -a

列出您的接口。 它应该是这样的:

 lo0:1: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1
    inet 127.0.0.1 netmask ff000000 
 bge0:1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 2
    inet 123.45.123.45 netmask ffffff00 broadcast 123.45.123.255

这里接口名称是 bge0。 (lo0 是环回接口;您不希望这样)您的接口可能会被称为不同的名称 - 可能是 e1000g0,具体取决于 VMWare 提供的网络接口类型。

请注意,由于您在全局区域和子区域中使用相同的网络接口,因此您必须为子区域选择与全局区域位于同一子网上的 IP 地址。
在上面的示例中,bge0 的网络掩码为 255.255.255.0,这意味着您的子区域 IP 需要介于 123.45.123.0 和 123.45.123.254 之间

Since you want to SSH into the zone from outside, it needs to have it's own IP address on the same network as the global zone. So either find a free address in the same network, or ask your network administrator to allocate one - whichever you usually do.

For the 'physical' setting; here (I think) is the simplest case: If you've allocated a single virtual network interface to your VM, then use that interface for the 'physical' setting

So, in the global zone, do

/usr/sbin/ifconfig -a

to list your interfaces. It should say something like

 lo0:1: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1
    inet 127.0.0.1 netmask ff000000 
 bge0:1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 2
    inet 123.45.123.45 netmask ffffff00 broadcast 123.45.123.255

Here the interface name is bge0. (lo0 is the loopback interface; you don't want that) Yours will likely be called something different - maybe e1000g0, depending on what kind of a network interface VMWare presents.

Note that since you're using the same network interface in the global zone and the child zone, you must choose an IP address for the child on the same subnet as the global zone's.
In the example above the netmask for bge0 is 255.255.255.0, which means your child zone IP needs to be between 123.45.123.0 and 123.45.123.254

貪欢 2024-07-24 01:21:34

这实际上非常简单,区域常见问题解答包含大部分内容问题,但基础知识是

  • 使用 >zonecfg(1)
    • 区域配置数据的详细信息为此处,但一般来说默认值很有用
    • 您可能需要一个 共享 IP 配置,除非您使用 vmware 做了一些创造性的事情
  • root 身份登录到该区域
  • 进行了一些创造性操作,确保 ssh 服务已启动running

然后你就应该被设置了。 阅读有关区域的 BigAdmin 文章系统管理指南部分也不会造成伤害。

This is actually pretty easy, The Zones FAQ has most of the questions, but the basics are

  • create a zone using zonecfg(1)
    • details of zone configuration data is here but in general the defaults are useful
    • you probably want a shared-IP configuration unless you have done something creative with vmware
  • log into the zone as root
  • make sure the ssh service is running

You should then be set. Reading the BigAdmin articles on Zones and the Sysadmin guide section wouldn't hurt either.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文