Getting started with NextCloudPi on Proxmox

Hi @nachoparker and @michuvon

I tried this new image but now I get “not a bootable disk”:
image

I repeated the process a couple of times but no go…

Sorry for the late response.
It is allowed to ask stupid questions, if not I would have to leave a long time ago.


Did you do step 3.4

If you did that, it’s beyond my ability.
If I have time I’ll test it myself.

but you can try Option 2,
that’s what I did, that way I can customoze the VM after my needs.

Hi @michuvon ,

Indeed I changed the boot disk to the one, but since my memory is not that amazing, I quickly repeated the process but still got:
image

… but the import seemed OK to VM ID 100:

… enabled the disk on the boot options menu, disabled eth/cdrom boot:
image

… and here showing in the summary, the imported disk as main disk:

I don’t know where to start to debug this :frowning:

I will wait for @OliverV or @nachoparker to pitch in when they have the time.

Hi again @michuvon

Option 2 is OK too, I had it working before like that but wanted to explore the VM option. At the moment, my instance is running on a dedicated i7 laptop, Debian 10 with 1TB SSD ad 16GB RAM.

I actually I would like to go for the Proxmox CT option but was unable to find a solution.

Thanks!
ER.

This (latest) VM image worked for me.
Terminal commands used and output here

I used an existing VM, added the drive to it and set it to boot
After boot visited local IP and went through activation, worked like charm.
image

Appreciate taking the time for the test and provide your feedback, I am not sure what I am doing wrong :frowning: here are the full steps I am taking with every single option I change:

Proxmox with NCP VM

I highlight the places where I make any changes
image

image
Changed from other disk I have, set HDD to 8Gb because I can’t proceed without adding a disk here… then I enable SSD and Discard as the LVM is on a SSD

image

image

image

Here is the output from Proxmox shell:

root@pve:/var/lib/vz/images# qm importdisk 102 NextCloudPi_VM_11-08-21.img wdblue-zfs
importing disk 'NextCloudPi_VM_11-08-21.img' to VM 102 ...
transferred 0.0 B of 20.0 GiB (0.00%)
transferred 204.8 MiB of 20.0 GiB (1.00%)
transferred 413.7 MiB of 20.0 GiB (2.02%)
...
transferred 20.0 GiB of 20.0 GiB (99.96%)
transferred 20.0 GiB of 20.0 GiB (100.00%)
transferred 20.0 GiB of 20.0 GiB (100.00%)
Successfully imported disk as 'unused0:wdblue-zfs:vm-102-disk-1'
root@pve:/var/lib/vz/images# 

Then I go to the VM > Hardware and I see the unused disk there:
image

Double click it and:

Then enable it in Options > Boot Order:
image

and it fails to boot:

Could you point me at the right direction where the mistake it?

Thanks,

Hello All, I followed the description of option 3. VM in Proxmox using the latest ISO image. Everything worked as it should. Thank you for the very good tutorial! Now my problem, I can reach the NCP web interface with my browser but I’m not able to get the SSH access to work. I tried to activate ssh over the NCP config panel for the pi user but the message was the user pi does not exist. So I tried with root user which worked. But now I get the message “Permission denied (publickey)” when I try to set up the ssh connection. I tried to check some ssh config via PVE console but every time I fill out my login data (ncp login) the blue NCP picture pops up a second and then I got thrown out to login again. Thus I have no access to my VM via the terminal, can anyone help? And please ask if you need further information! Thank you in advance!

1 Like

@Dani-Pi

You manage to get the VM to boot normally?

Could you check my post here: Getting started with NextCloudPi on Proxmox - #31 by Edson_Rodrigues

… and see what are the differences? I can’t get the VM image to boot :sob:

Thanks,
Edson

@Edson_Rodrigues Hi, the only thing I did different is I haven’t checked the SSD emulation checkbox and I do not have a zfs file system

Do you have any idea, why I do not have a pi user and why my SSH is not working?

Hi @Dani-Pi ,

So sorry, without access via SSH is quite difficult to debug that :thinking:. I guess that root access via SSH is disabled but I think that it should be enabled by default.

Maybe @OliverV or @nachoparker can chip in with their view. Pretty sure they will have an idea.

Thanks for your reply on my post, I will give it a try to see if I can make the image boot, maybe I can also reproduce the same issue? fingers crossed.b

Thanks,
ER

1 Like

I give up… I can figure out what I am doing wrong :frowning:

image

I tried installing in the “local-lvm” but same thing :frowning:

running

qm importdisk 105 NextCloudPi_VM_11-08-21.img local-zfs

did the trick for me, check link in my post above, for all commands I passed to PVE terminal.
Once that is done, rest can be done from the webUI.

Hi @OliverV

I did the radical thing and wiped all Proxmox and reinstalled it…

I repeated the process and I was able to boot the VM :slight_smile: thinking back, VERY likely it was the img that was corrupted and I never tried re-downloading the tar.bz2 :expressionless: that should’ve been one of my “retry” options.

Anyway, now seems ok and I will start more tests.

@Dani-Pi

I was able to boot the VM and auth with root/ownyourbits on the proxmox VM shell. Via SSH I was not able to get a session so I went to the NCP webUI on port 4443 and enabled SSH:

I tried SSH and I was able to get a prompt. Once I hit root > enter, I got disconnected and now I get:

image

When I went back to the Proxmox VM shell I authenticated with root/ownyourbits but this time I got a prompt:

I changed the password and I was inside the Proxmox VM shell, then I edited /etc/ssh/sshd_config

changed:

#PermitRootLogin prohibit-password

to:

PermitRootLogin yes

and also changed:

PasswordAuthentication no

to:

PasswordAuthentication yes

This worked for me and I am able to login via SSH and root.

Thanks!
ER.

@Dani-Pi

I can’t find the “pi” user so maybe it is not included in the VM version?

getent passwd | awk -F: ‘{ print $1}’

root
daemon
bin
sys
sync
games
man
lp
mail
news
uucp
proxy
www-data
backup
list
irc
gnats
nobody
_apt
systemd-timesync
systemd-network
systemd-resolve
messagebus
uuidd
sshd
_chrony
vagrant
systemd-coredump
mysql
postfix
redis
ncp
_rpc
statd
dnsmasq
prometheus
avahi

@Edson_Rodrigues Hi, thank you for your detailed feedback! Yes, that’s the way it should work. I will try it again in some days. I solved the problem with using the CURL Installer instead of ISO image to built up the NCP VM. Because of the pi user I think so too. Has something to do with VM ISO.

1 Like

@Dani-Pi

The curl installer worked 100% for you?

I am asking this because it always worked for me but the last times I tried to useit, I always get a error when the script is just about to finish :frowning: I think it could be a “bug” as I seen this issue happening in other situations. For the first time I posted in github:

Instalation script fails with: Column “oc_preview_generation”.“locked” is type Bool and also NotNull, so it can not store “false”. #1391

From several posts in the forum to github, I see that people like @nachoparker and @OliverV are pretty much hands-tied and cannot support/verify everything so I will wait patiently for a reply.

Cheers,
ER

EDIT: I found my error. I had installed a nextcloud LXD, not a nextcloud pi LXD. :laughing: I’ll try to get the nextcloudpi one running now.

I am trying to install nextcloudpi using method one: :new: LXD option! I already have ncp running on a pi (for a while now, maybe a year?) and I’m looking to port it over to my shiny new NUC. :slight_smile:

I’m happy to share the steps I’ve done to make whatever modest improvements I can to the documentation that you kindly maintain. :slight_smile:

I’m stuck at the moment on the splash page. I’m getting hit with the " Access through untrusted domain" message on the web gui, and when I log in through the console in proxmox, I am prompted for “NextCloudPi login:”, but none of the user/password combos mentioned here have granted me access (root/root, root/ownyourbits, root/vagrant). Are there any other passwords or methods that I can try?

My process thus far:

To start, I used the proxmox console to check the available containers (as described in the proxmox docs:

pveam available

I then copied the line for nextcloud and downloaded it with:

pveam download local debian-10-turnkey-nextcloud_16.1-1_amd64.tar.gz

From there I created the container in the GUI. I’ll try using the command line the next time I do this (I am going to help a friend if I succeed) as that is usually easier to document.

I tried to import the LXD into proxmox directly via url from the tar.gz link at Index of /downloads/NextCloudPi_LXD_10-08-21/

However, it appears that proxmox wants a tar.gz file, so I downloaded the tar.bz2 , uncompressed it with 7-zip, and then recompressed it as a tar.gz. I was able to upload the tar.gz into proxmox, but when I tried to create a container from it I got approximately one million errors. They all look like this:

Creating filesystem with 2097152 4k blocks and 524288 inodes
Filesystem UUID: cb109969-4b6f-4531-9649-7e18ee983e11
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632
extracting archive '/var/lib/vz/template/cache/NextCloudPi_LXD_10-08-21.tar.gz'
tar: backup/container/rootfs/bin: Cannot change ownership to uid 100000, gid 100000: Invalid argument
tar: backup/container/rootfs/boot: Cannot change ownership to uid 100000, gid 100000: Invalid argument
tar: backup/container/rootfs/dev: Cannot change ownership to uid 100000, gid 100000: Invalid argument
tar: backup/container/rootfs/etc/.pwd.lock: Cannot change ownership to uid 100000, gid 100000: Invalid argument
tar: backup/container/rootfs/etc/adduser.conf: Cannot change ownership to uid 100000, gid 100000: Invalid argument
tar: backup/container/rootfs/etc/aliases: Cannot change ownership to uid 100000, gid 100000: Invalid argument

I wonder if my 7-zip chicanery caused this. Does anyone have any advice on how to get the proper file into proxmox?

Hi @igijfl nice to see that you also try to get it working.
I haven’t had much time these days but was finally able to put a post together about my attempts.

I got a bit further than you, but it’s not yet working either.
See this post >> Making it possible: NextCloudPi LXD on Proxmox

For option 3, the link https://ownyourbits.com/downloads does not work anymore. And on nextcloudpi.com, VM install is mentioned, but under downloads (Releases · nextcloud/nextcloudpi · GitHub) I do not see any download for a VM?!

On the section " Pass through a drive that is used for NCP data" I am a bit lost.
I have installed NCP in Proxmox and want to continue using the HDD that so far I was using in NCP in my Raspberry Pi.
So far my datadir was /media/USBdrive/ncdata.
In the proxmox installation it is /var/www/nextcloud/data.
As it looks like I cannot change this, would I need to mount the HDD folder into /var/www/nextcloud/data? I guess that is not possible to mount into this folder, isn´t it?
But as the nc-datadir option is not available in ncp-config, what do I do?