AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题 / 401397
Accepted
Richard Whitman
Richard Whitman
Asked: 2012-06-23 09:38:36 +0800 CST2012-06-23 09:38:36 +0800 CST 2012-06-23 09:38:36 +0800 CST

将 Juniper EX3300 交换机用作路由器?

  • 772

我在数据中心有一台 Juniper EX3300 交换机。我已将其中一个上行链路端口 (ge-0/1/0) 连接到我的 ISP 路由器。我想配置一下,让所有和ge-0/1/0在同一个VLAN的端口连接的设备都能上网。我做了一些研究,但我真的没有得到任何地方。

我已经配置界面如下:

ge-0/1/0 {
    ether-options {                 
        no-auto-negotiation;
        link-mode full-duplex;
        speed {
            1g;
        }
    }
    unit 0 {
        family inet {
            address xx.xx.xx.xx/32;
        }
    }
}

其中 xx.xx.xx.xx 是我的 ISP 分配的“客户路由器端口 IP”。

当我尝试提交时,出现以下错误:

Interface ge-0/1/0.0 not enabled for switching

有人可以告诉我配置它的正确方法是什么吗?

juniper junos
  • 1 1 个回答
  • 5781 Views

1 个回答

  • Voted
  1. Best Answer
    Mike Pennington
    2012-06-23T10:55:43+08:002012-06-23T10:55:43+08:00

    不清楚你想要下面的拓扑A还是B(我觉得你需要B,但是你的问题好像是要A)

              Vlan10           Vlan10
    A) [Users]----------[EX330]----------[ISP]
                       x.x.x.x/zz
    
              Vlan10           Vlan11
    B) [Users]----------[EX330]---------------------------[ISP]
                  y.y.y.y/24  xx.xx.xx.109/30     .110/30
    

    A)
    这是一个平面 layer2 vlan,您的所有计算机都必须在 ISP 的子网上寻址。Vlan-10 用于所有机器,它们将默认网关设置为 xxxx

    我不确定您为什么在问题中使用 /32 掩码。您不太可能想要这样做,因为这意味着您为所有目的地代理 arp。与您的提供商合作以了解您的实际网络掩码应该是什么(我假设 zz,如下所示)

    delete interfaces ge-0/1/0 unit 0
    delete interfaces ge-0/1/0
    delete interfaces ge-0/1/1 unit 0
    delete interfaces ge-0/1/1
    set vlans vlan-10 vlan-id 10
    set vlans vlan-10 interface ge-0/1/0
    set vlans vlan-10 interface ge-0/1/1
    set interfaces ge-0/1/0 unit 0 family ethernet-switching port-mode access
    set interfaces ge-0/1/1 unit 0 family ethernet-switching port-mode access
    set interfaces vlan unit 10 family inet address x.x.x.x/zz
    set routing-options static route 0.0.0.0/0 next-hop xx.xx.xx.110
    

    B)
    这涉及两个不同的 vlan:10 和 11。Vlan-10 用于您的所有服务器,它们将默认网关设置为 yyyy

    delete interfaces ge-0/1/0 unit 0
    delete interfaces ge-0/1/0
    delete interfaces ge-0/1/1 unit 0
    delete interfaces ge-0/1/1
    set vlans vlan-10 vlan-id 10
    set vlans vlan-11 vlan-id 11
    set vlans vlan-10 interface ge-0/1/0
    set vlans vlan-11 interface ge-0/1/1
    set interfaces ge-0/1/0 unit 0 family ethernet-switching port-mode access
    set interfaces ge-0/1/1 unit 0 family ethernet-switching port-mode access
    set interfaces vlan unit 11 family inet address xx.xx.xx.109/30
    set interfaces vlan unit 10 family inet address y.y.y.y/zz
    set routing-options static route 0.0.0.0/0 next-hop xx.xx.xx.110
    

    根据需要为 Vlan-11 中的服务器添加任意数量的端口。如果您的提供商没有足够的公共地址空间来包含 Vlan10 和 Vlan11 的子网,则解决方案 B必须使用某种形式的 NAT

    • 4

相关问题

  • 瞻博网络 SSG5 防火墙

  • 无法进入瞻博网络 Netscreen Web 界面

  • 瞻博网络防火墙 - 用于测试的大型 ping

  • 我可以在瞻博网络 M10i 路由器中使用第三方 Compact Flash 吗?

  • SSRS 导出到 Excel 无法通过 VPN (Juniper SA4000)

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve