NextCloud VM - How to set static IP?

,

Hello,

I downloaded the NextCloud VM and imported that as VirtualBox VM in my home PC. Everything went fine but it seems by default the VM is configured to fetch dynamic IP from my home router DHCP.

Virtual Box VM is configured as bridged network to unrestricted access to my home network.

I would like to set a static IP address for this VM.

My main purpose for nextcloud is to try and find an alternative to Google Photos for me and my familiy members & I am not that good with Linux, I did try to search and follow some guides on editing a yaml file but got stuck at editing the config file of NextCloud, as I am unable to locate the exact location.

Is there any easy way to edit the IP Address of the VM during installation to set it to use a static IP address?

Thanks.

Hi,

Please check this out:

https://docs.hanssonit.se/s/W6fMouPiqQz3_Mog/virtual-machines-vm/d/W6fMquPiqQz3_Moi/nextcloud-vm-first-setup-instructions

You could also just run the static IP script from console to get it all done automatically.

sudo bash /Var/scripts/menu.sh → Server Configuration → Static IP.

Hope it helps!

Hello,

Thanks for the reply.

Could you please tell me at which stage of installation process I am supposed to run this? Since once I start the VM, it goes into Auto Installation mode and runs through the installation / setup process without ever asking me to make selection of IP Address.

Now after it completes the installation, it has already done everything based on the IP it got from DHCP (as explained in that documentation link given by you).

At this stage, if I am trying to execute “sudo bash /Var/scripts/menu.sh” in VM, it is throwing error that file doesn’t exists.

Capture

Second alternative is to setup the DHCP server MAC / IP binding.

It worked that way, however, that’s problematic for me as I can’t move the VM to somewhere else as it will be depended on that specific DHCP server or otherwise, everywhere else I need to have access to DHCP for IP / MAC binding.

Can’t I set the network IP at Ubuntu / NextCloud itself?

I wonder why “sudo bash /Var/scripts/menu.sh” isn’t working !!

Thanks.

Update 1:

I found installing nextcloud via snap is much easier for my need as I can set a static IP while installing ubuntu server on VM. Thanks.

Are you running the latest VM from here?

I don’t think so since menu.sh is default in the last 3-ish versions.

Hi, I downloaded the latest vm, an updated it. But the menu.sh is still missing

Hi, please read this:

There’s a typo in the command “V” should be lowercase.

Hello @ADust

Thanks for the reply.

You are correct, in Linux, upper and lower case characters are treated as different so /Var and /var are two different directories / files.

However, I was trying both, if you may please refer to the screenshot in my previous post, I have both since original /var/… command was throwing error.

However, as I have written above, after failing to get the Official VM Image running, I shifted to snap installation method on a clean Ubuntu 20 VM and it worked as per my liking.

This is an old post, when I was first tinkering with NextCloud to learn the basics of it.

Its been many months now & presently I have a dedicated Computer (Laptop hardware actually) running live with a TLD and SSL along with NextCloud snap serving my purpose.

Capture

Thanks

Hello NaXal,
just wanted point it out to newbies like myself, if they come across. Because on my system this command actually helped my to recover the system (i may have a different version).

Regards

1 Like

After opening the .ova file, the IP address is not obtained automatically. How can I assign an ip address

@tipoti Interesting, where did you download this VM from?

Scratch that, I can see that it’s the AIO VM. You should download the VM here:

1 Like

Hi i download it from here:
https://download.nextcloud.com/aio-vm/