Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Proxmox

You're reading from   Mastering Proxmox Master Proxmox VE to effectively implement server virtualization technology within your network

Arrow left icon
Product type Paperback
Published in Jul 2014
Publisher
ISBN-13 9781783980826
Length 310 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Wasim Ahmed Wasim Ahmed
Author Profile Icon Wasim Ahmed
Wasim Ahmed
Arrow right icon
View More author details
Toc

Table of Contents (12) Chapters Close

Preface 1. Dive into the Virtual World with Proxmox FREE CHAPTER 2. Proxmox Under the Hood 3. Shared Storages with Proxmox 4. A Virtual Machine for a Virtual World 5. Network of Virtual Networks 6. Proxmox HA – Zero Downtime 7. High Availability Storage for High Availability Cluster 8. Proxmox Production Level Setup 9. Proxmox Troubleshooting 10. Putting It All Together Index

Adding NAT/masquerading


NAT is a way to hide internal network IP addresses from the external network, such as the Internet. Any outgoing traffic uses the main host IP address instead of using own local IP address. Add the last three lines of the following post-up and post-down settings in the configuration file /etc/network/interfaces. Only add these lines under the virtual bridge configuration which needs the NAT option. Have a look at the following code snippet:

auto vmbr0
iface vmbr0 inet static
address 192.168.145.1
netmask 255.255.255.0
bridge_ports none
bridge_stp off
bridge_fd 0post-up echo 1 > /proc/sys/net/ipv4/ip_forward
post-up iptables -t nat -A POSTROUTING -s '192.168.145.0/24' -o eth0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '192.168.145.0/24' -o eth0 -j MASQUERADE

Tip

It is much easier and manageable to handle NAT using a physical or virtual firewall. Most of the firewalls have the NAT option out of the box. Also, using virtualized firewalls, we can create...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime