我最近在运行Vagrant的CentOS6VM上安装了mongodb。我将端口转发添加到Vagrantfile以转发mongo端口config.vm.forward_port27017,127017我将mongod配置为在服务器启动时自动启动,并已确认该服务按预期启动。然而,当我从我的主机(不是vagrant)运行mongolocalhost:127017时,我得到以下错误MongoDBshellversion:1.8.2connectingto:localhost:127017/testFriJan2013:58:28getaddrinfo("127.0.0.1")failed:no