Skip to content

Commit

Permalink
Update a post: qemu-socket-vmnet.md
Browse files Browse the repository at this point in the history
  • Loading branch information
adonis0147 committed May 27, 2024
1 parent 504f93b commit f55f63a
Showing 1 changed file with 30 additions and 3 deletions.
33 changes: 30 additions & 3 deletions content/post/qemu-socket-vmnet.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,33 @@ socket_vmnet_client "$(brew --prefix)/var/run/socket_vmnet" \

# Log into the server by SSH

```shell
ssh 192.168.105.2
```
1. Get the name of the network device.

```shell
$ ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp0s1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
link/ether 52:54:00:12:34:56 brd ff:ff:ff:ff:ff:ff
```

We can see the name of the network device is `enp0s1`.

2. Get the ip address

```shell
$ ip route
default via 192.168.105.1 dev enp0s1 proto dhcp src 192.168.105.2 metric 100
192.168.105.0/24 dev enp0s1 proto kernel scope link src 192.168.105.2 metric 100
192.168.105.1 dev enp0s1 proto dhcp scope link src 192.168.105.2 metric 100
```

We can see the ip address is `192.168.105.2`.

3. Log into the server

```shell
ssh 192.168.105.2
```

0 comments on commit f55f63a

Please sign in to comment.