Stéphane CLINCKART's picture

Hello,

I tried several turnkey solution installed like following on proxmox:

pct create 101 VMHost:vztmpl/debian-11-turnkey-postgresql_17.1-1_amd64.tar.gz --hostname postgresql-17.1-1 --cores 2 --memory 1024 --swap 512 --rootfs VMHost:128 --net0 name=eth0,bridge=vmbr0,ip=192.168.100.20/22,gw=192.168.100.1 --onboot 1 --startup 'order=1,up=5,down=5'

After I tried to connected:

1) with putty via ssh root@192.168.100.20 it ask me to accept a certificate then ask me for a password.

2) from proxmox console via ssh root@192.168.100.20 but same thing happened.

The password wizard didn't show up.
I restarted several time the VM.

I don't know what to try else.

Thanks for support,
Kind regards
Stéphane

Forum: 
Jeremy Davis's picture

When you first log in via SSH, you should be greeted by the firstboot scripts.

The only thing that I can think of is perhaps it wasn't quite ready yet? If you log in before the interactive component of the firstboot process has started, then perhaps that might occur? I'm not sure if pct provides a way to see what the boot process is doing, but you can open a NoVNC window (from the Web UI) - once it reaches the log in prompt you should be good to go (I prefer using SSH, but the NoVNC window should work fine).

Update: This should work:

pct console VMID

I.e. 'pct console 101'. I just tested it and you can log in via that too and should see the firstboot scripts. Note to exit: 'Ctrl-a' followed by 'q'.

Hopefully that helps. If you continue to have issues, please post back and I'll test myself.

Stéphane CLINCKART's picture

Hello, thanks for quick reply.

Here the command line and the result:

root@proxmox1:~# pct create 101 VMHost:vztmpl/debian-11-turnkey-postgresql_17.1-1_amd64.tar.gz --hostname postgresql-17.1-1 --cores 2 --memory 1024 --swap 512 --rootfs VMHost:128 --net0 name=eth0,bridge=vmbr0,ip=192.168.100.20/22,gw=192.168.100.1 --onboot 1 --startup 'order=1,up=5,down=5'
Formatting '/mnt/pve/VMHost/images/101/vm-101-disk-0.raw', fmt=raw size=137438953472 preallocation=off
Creating filesystem with 33554432 4k blocks and 8388608 inodes
Filesystem UUID: b2501c7e-5a32-4eb2-be50-e24e29e9bb69
Superblock backups stored on blocks: 
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 
        4096000, 7962624, 11239424, 20480000, 23887872
extracting archive '/mnt/pve/VMHost/template/cache/debian-11-turnkey-postgresql_17.1-1_amd64.tar.gz'
Total bytes read: 979159040 (934MiB, 183MiB/s)
Detected container architecture: amd64
Creating SSH host key 'ssh_host_dsa_key' - this may take some time ...
done: SHA256:EEBE071ae3ZH1R7Qe+3srvlqo2/YuXd+4/q/wE6Z9rc root@postgresql-17
Creating SSH host key 'ssh_host_ed25519_key' - this may take some time ...
done: SHA256:7qJaU9PXWaSDTDH69jISdP3QoqCQ73oNFWEXU8cUzbc root@postgresql-17
Creating SSH host key 'ssh_host_rsa_key' - this may take some time ...
done: SHA256:SwVUQMDnnIfP5a2Wn6tie0Ou5/dRNFdVtLJrYqx/RSQ root@postgresql-17
Creating SSH host key 'ssh_host_ecdsa_key' - this may take some time ...
done: SHA256:+YIcGJsf9cJvDojKYhfvX4XQYoG9eeviVIai/0b0d2w root@postgresql-17


Then, after a while, I was trying different ways to login.

pct console 101, noVNC, SSH via putty... always the same result:

Linux proxmox1 5.15.74-1-pve #1 SMP PVE 5.15.74-1 (Mon, 14 Nov 2022 20:17:15 +0100) x86_64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Mon Mar  6 20:14:40 CET 2023 on pts/0
root@proxmox1:~# pct console 101

Connected to tty 2
Type <Ctrl+a q> to exit the console, <Ctrl+a Ctrl+a> to enter Ctrl+a itself

Login timed out after 60 seconds.

Debian GNU/Linux 11 postgresql-17 tty2

postgresql-17 login: 
Password: 

Login incorrect
postgresql-17 login: root
Password: 

Login incorrect
postgresql-17 login: 
Login timed out after 60 seconds.

Debian GNU/Linux 11 postgresql-17 tty2

postgresql-17 login: 

I checked the activity summary of the VM  after 8 minutes:

CPU : 0.05%
MEM: 55 MB
DISK: 1 GB

I really don't know what to do.
Specially I tried another installation on a different node, same problem.

Is there a way to watch the logs ?

Thanks
Kind regards
Stéphane

 

Jeremy Davis's picture

I'm sorry that I missed it in your initial post. Whilst the firstboot scripts set app passwords etc, you need to set the root password via Proxmox when launching the container.

TBH, I mostly use the web UI but a quick look at the pct doc page it looks like you'll want to add the '--password' switch with your desired root password. I.e. add this to your launch line:

 --password <password>

Then you should be able to log in as root. Once you've logged in, that's when you should be greeted by the firstboot scripts that have been mentioned. Sorry I missed that from your initial post.

Stéphane CLINCKART's picture

Hello Jeremy,

Thanks a lot... so simple fix.
You opened now a new door for me to explore all the turnkey solutions.

Thanks a lot

Stéphane

Jeremy Davis's picture

Glad to hear that got you over the line!

Please don't hesitate to post back if you have any further questions, concerns or any other feedback (e.g. things that could be better or aren't as clear as they should be).

Good luck with it all.

Add new comment