Cant connect!
- Lets try pinging Google
ping 8.8.8.8
if connected, check the Understanding New IP and Port Forwarding down below
if not continue here
- Getting a new IP
Lets re-generate out network config
sudodhclient
- Getting yur netowrk card
run this command
ifconfig
and check for your local ip and check the network card to the left
- Edit your network config
Go to the root directory of the server/desktop and edit etc/netoplan/00-installer-config.yaml
etc/netoplan/00-installer-config.yaml
netowrk for VMs as examples
network:
version: 2
ethernets:
ens33: # << Change to network card name
addresses: [192.168.1.65/24] # << Change to VM name
gateway4: 192.168.1.2
nameservers:
addresses: [1.1.1.1, 1.0.0.1]
Understanding New IP and Port Forwarding
When you're setting up a new IP address for your network, there are a few things you need to keep in mind, particularly when it comes to port forwarding and static leases.
Port Forwarding
Port forwarding is a technique used to allow external devices to access services on your internal network. This can be useful for things like hosting a server, or running a home security camera system.
If you're experiencing issues with port forwarding on your new IP address, the first thing you should check is that your router's port forwarding settings are properly configured. This typically involves specifying the internal IP address of the device you want to forward ports to, as well as the specific ports that need to be opened.
If you're still having trouble, you may need to check your router's firewall settings to ensure that they're not blocking the incoming connections. Additionally, you may need to check that your router's firmware is up to date, as some older versions may have bugs that can cause port forwarding issues.
Static Leases
Static leases are used to assign a specific IP address to a specific device on your network. This can be useful if you have a device that you want to always have the same IP address, such as a server or a gaming console.
If you're having issues with static leases on your new IP address, the first thing you should check is that your router's DHCP settings are properly configured. This typically involves specifying the MAC address of the device you want to assign a static IP to, as well as the specific IP address you want to assign.
If you're still having trouble, you may need to check your router's DHCP settings to ensure that there are no conflicts with other devices on your network. Additionally, you may need to check that your router's firmware is up to date, as some older versions may have bugs that can cause DHCP issues.
Notes
- Port Forwarding
- Allows external devices to access internal network services
- Examples: hosting a server, running a home security camera system
- Requires proper configuration of router's port forwarding settings
- Specify internal IP address of device to forward ports to
- Specify specific ports to be opened
- Troubleshooting:
- Check router's firewall settings to ensure incoming connections are not blocked
- Check router's firmware is up to date (older versions may have bugs that can cause port forwarding issues)
- Note: Port Forwarding can also be a security risk if not configured properly.
- Port Forwarding can be vulnerable to security threats if not properly configured.
- It can expose the internal network to external attacks, by opening up access to internal services that may not be properly secured.
- It is important to only forward ports that are necessary, and to keep the internal services updated with the latest security patches.
- It is also important to regularly check your router's logs for suspicious activity and to monitor your network for unusual traffic.
- For important and sensitive services, it is recommended to use VPNs or other secure protocols for remote access.
- Additionally, it is recommended to use a firewall to further secure your network from external threats.
VSCode SSH error
Key error
To fix a key verifaction error head to file exploer and head to c:/users/<username>/.shh/known_hosts and clear the key that you were trying to access and try again to connect