B4J Question Changing IP address in B4J App

aaronk

Well-Known Member
Licensed User
Longtime User
Hi,

I am planning on running my B4J app on a Linux device, and I am trying to work out how to run a function to change the IP address of the Linux device.

I have done some research and I think the following commands should allow me to change the IP address.

Change to DHCP:

echo “iface eth0 inet dhcp” >>/etc/network/interfaces


Force a Static IP:

ifconfig eth0 192.168.0.34
ifconfig eth0 netmask 255.255.255.0
ifconfig eth0 broadcast 192.168.0.255


Anyone know how can I run the above commands in my B4J app?

Or is there another way in changing the IP address of the device in B4J?
 
Top