SV: SSVM stopped and will not be recreated.... :-(

2023-04-18 Thread David Larsen
Hi Jithin

Thanks
I tried to destroy the SSVM (s-1178-VM) again and the same happened.
When I destroyed the s-1178-VM,  a new secondarystoragevm  (s-1179-VM) is 
created in Cloudstack, but not in vmware. The new s-1179-VM have state 
"Stopped" in Cloudstack, the old s-1178-VM is gone from Cloudstack, but not in 
vmware...(?)
We are using vcenter 7.0.3 build 21290409, ESXi vsphere 7.0.3 build 20842708

When I search the logs, I see the "GetVolumeStatsCommand" is looking for an 
older secondarystoragevm (s-1177-VM).(?)
Why is it asking for a destroyed secondarystoragevm?

Some logs bellow:

tail -f /var/log/cloudstack/management/management-server.log | grep secstorage
2023-04-18 18:42:06,457 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-5fbc0852) (logid:da43d2ce) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:42:36,452 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-46384dc3) (logid:d00b7246) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:43:06,455 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-4f4a13fd) (logid:7a2e9b74) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:43:36,455 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-cc2d5863) (logid:e71c579c) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:44:06,451 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-1edf7982) (logid:eedb5033) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:44:06,455 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-1edf7982) (logid:eedb5033) No running secondary storage vms 
found in datacenter id=5, starting one
2023-04-18 18:44:06,458 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-1edf7982) (logid:eedb5033) Found SSVMs that are currently at 
stopping state, wait until they are settled
2023-04-18 18:44:36,459 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-82a430e4) (logid:463b8153) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:44:36,464 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-82a430e4) (logid:463b8153) No running secondary storage vms 
found in datacenter id=5, starting one
2023-04-18 18:44:36,468 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-82a430e4) (logid:463b8153) Found SSVMs that are currently at 
stopping state, wait until they are settled
2023-04-18 18:45:06,455 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:45:06,459 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) No running secondary storage vms 
found in datacenter id=5, starting one
2023-04-18 18:45:06,462 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Allocate secondary storage VM 
standby capacity for zone [5].
2023-04-18 18:45:06,465 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Found a stopped secondary storage 
VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"}, starting it.
2023-04-18 18:45:06,477 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) start parameter value of 
enterHardwareSetup ==  during processing of queued job
2023-04-18 18:45:06,504 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Sync job-13757 execution on object 
VmWorkJobQueue.1178
2023-04-18 18:45:08,480 DEBUG [c.c.a.SecondaryStorageVmAlertAdapter] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) received secondary storage vm alert
2023-04-18 18:45:08,482 DEBUG [c.c.a.SecondaryStorageVmAlertAdapter] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Secondary Storage Vm creation 
failure, zone: Zone1
2023-04-18 18:45:08,483 WARN  [c.c.a.AlertManagerImpl] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) alertType=[19] dataCenterId=[5] 
podId=[null] clusterId=[null] message=[Secondary Storage Vm creation failure. 
zone: Zone1, error details: Unable to allocate capacity on zone [5] due to 
[null].].
2023-04-18 18:45:08,506 WARN  [c.c.v.SystemVmLoadScanner] 
(secstorage-1:ctx-36cf6e8c) (logid:56ad8856) Unexpected exception Unable to 
orchestrate start VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1178].
2023-04-18 18:45:36,454 DEBUG [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-1e85449e) (logid:5c0bed1c) Zone [5] is ready to launch 
secondary storage VM.
2023-04-18 18:45:36,458 INFO  [o.a.c.s.PremiumSecondaryStorageManagerImpl] 
(secstorage-1:ctx-1e85449e) (logid:5c0bed1c) No running secondary storage vms 
found in datacenter id=5, starting one
2023-04-18 18:45:36,461 DEBUG 

SSVM stopped and will not be recreated.... :-(

2023-04-17 Thread David Larsen
ate start VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1178].
com.cloud.utils.exception.CloudRuntimeException: Unable to orchestrate start VM 
instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1178].
2023-04-17 22:13:23,660 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-7a63db20) (logid:91af80f4) Found a stopped secondary storage 
VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"}, starting it.
2023-04-17 22:13:25,228 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-33:ctx-db5e9ae2 job-12251/job-12284 ctx-c05a2869) 
(logid:c33fffa8) orchestrating VM start for 's-1178-VM' 
com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d<mailto:com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d>
 set to null
2023-04-17 22:13:25,237 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-33:ctx-db5e9ae2 job-12251/job-12284 ctx-c05a2869) 
(logid:c33fffa8) VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} state 
transited from [Stopped] to [Starting] with event [StartRequested]. VM's 
original host: null, new host: null, host before state transition: null
2023-04-17 22:13:25,238 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-33:ctx-db5e9ae2 job-12251/job-12284 ctx-c05a2869) 
(logid:c33fffa8) Successfully transitioned to start state for VM instance {id: 
"1178", name: "s-1178-VM", uuid: "457e6f90-8bb1-4026-b908-b11951f6", 
type="SecondaryStorageVm"} reservation id = b47c0d6e-3259-44aa-8fce-cb60f7c3e8df
2023-04-17 22:13:25,400 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-33:ctx-db5e9ae2 job-12251/job-12284 ctx-c05a2869) 
(logid:c33fffa8) VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} state 
transited from [Starting] to [Stopped] with event [OperationFailed]. VM's 
original host: null, new host: null, host before state transition: null
2023-04-17 22:13:25,402 WARN  [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-33:ctx-db5e9ae2 job-12251/job-12284 ctx-c05a2869) 
(logid:c33fffa8) Unable to orchestrate start VM instance {id: "1178", name: 
"s-1178-VM", uuid: "457e6f90-8bb1-4026-b908-b11951f6", 
type="SecondaryStorageVm"} due to [Unable to create deployment, no usable 
volumes found for the VM: 1178].
2023-04-17 22:13:25,502 WARN  [c.c.v.SystemVmLoadScanner] 
(secstorage-1:ctx-7a63db20) (logid:91af80f4) Unexpected exception Unable to 
orchestrate start VM instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1178].
com.cloud.utils.exception.CloudRuntimeException: Unable to orchestrate start VM 
instance {id: "1178", name: "s-1178-VM", uuid: 
"457e6f90-8bb1-4026-b908-b11951f6", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1178].

Med vennlig hilsen

David Larsen
Senior systemkonsulent

[cid:image001.png@01D9717D.B9FEE240]
ADCOM MOLDE, IT Data AS
Fabrikkvegen 13  | 6415 Molde
Mobil: 959 48 308 | Sentralbord: 71 25 06 40
david.lar...@adcom.no<mailto:david.lar...@adcom.no> | 
www.adcom.no<http://www.adcom.no/>

[Miljøfyrtårn][cid:image003.png@01D9717D.B9FEE240]

Følg oss på sosiale medier: [Facebook icon] 
<https://www.facebook.com/adcommolde/> [LinkedIn icon] 
<https://www.linkedin.com/company/10249752?trk=tyah=clickedVertical%3Acompany%2CclickedEntityId%3A10249752%2Cidx%3A2-1-2%2CtarId%3A1449043739552%2Ctas%3Aadcom%20molde>
P Tenk på miljøet før du skriver ut denne eposten




SV: SSVM - Getting "Unable to create deployment, no usable volumes found for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

2023-03-30 Thread David Larsen

Hi 

Any tips on how to get the SSVM agent up? 
Getting a bit frustrated!! 

The only error message I can see when ssvm boots up is: "Failed to start raised 
interface"

I can log into it from the console but not from ssh...
From the s-1177-VM console I have checked connectivity. I can ping the 
management server and public dns (google)

Any services or logs I have to check?
I checked the /var/log/cloud.log on the ssvm. 
Just a few lines there. Anything particular to look for?

Agent on consoleproxy is up..

What about the cloudstack Agent service on the management server?
Is it just for KVM or do I need it for vmware as well?
Looks like it's not running...

service cloudstack-agent stop
root@cloudstack02:~# service cloudstack-agent status
cloudstack-agent.service - CloudStack Agent
Loaded: loaded (/lib/systemd/system/cloudstack-agent.service; enabled; vendor 
preset: enabled)
Active: inactive (dead) (Result: exit-code) since Thu 2023-03-30 20:57:45 CEST; 
16min ago
Docs: http://www.cloudstack.org/
Process: 15391 ExecStart=/usr/bin/java $JAVA_OPTS $JAVA_DEBUG -cp $CLASSPATH 
$JAVA_CLASS (code=exited, status=66)
Main PID: 15391 (code=exited, status=66)

Mar 30 20:57:45 cloudstack02 systemd[1]: Stopped CloudStack Agent.
root@cloudstack02:~# service cloudstack-agent start
root@cloudstack02:~# service cloudstack-agent status
cloudstack-agent.service - CloudStack Agent
Loaded: loaded (/lib/systemd/system/cloudstack-agent.service; enabled; vendor 
preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Thu 2023-03-30 
21:14:43 CEST; 3s ago
Docs: http://www.cloudstack.org/
Process: 16882 ExecStart=/usr/bin/java $JAVA_OPTS $JAVA_DEBUG -cp $CLASSPATH 
$JAVA_CLASS (code=exited, status=66)
Main PID: 16882 (code=exited, status=66)

 Thanks

-David


-Opprinnelig melding-
Fra: David Larsen  
Sendt: torsdag 30. mars 2023 09:03
Til: users@cloudstack.apache.org
Emne: SV: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi Jithin

After i sent this email yesterday, I reverted back to ubuntu 18.04/cloudstack 
4.17.2/mysql 5.7.41 from snapshots. ☹ After about five minutes, the S-1177-VM 
was created successfully...(?) hmm.
The only problem with the S-1177-VM now is Agent State (down). I have tried to 
restart it several times. I have not yet restarted management server.

When I checked primary and secondary volumes with 4.18.0, all volumes was 
present in cloudstack. 
Which log can I check to see if the volume allocation worked fine for SSVM?



-Opprinnelig melding-
Fra: Jithin Raju 
Sendt: torsdag 30. mars 2023 05:39
Til: users@cloudstack.apache.org
Emne: Re: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi David,

Can you check in the logs if the volume allocation worked fine for SSVM? Is 
there a record present in the volumes table?

-Jithin

From: David Larsen 
Date: Thursday, 30 March 2023 at 1:31 AM
To: users@cloudstack.apache.org 
Subject: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi

Today i upgraded our Cloudstack (4.17.2 --> 4.18.0) , mysql (5.7--> 8) and  
ubuntu (18.04-->22.04) in production.
I thought I had tested it well in a lab... and of course  the only important 
thing I couldn't test went wrong!!
Secondary Storage VM...

At first it looked fine. I successfully upgraded console proxy system vm to 
4.18.0.
But when I tried to do the same with secondarystoragevm, stop it and wait for 
it to upgrade, Cloudstack  deleted the secondary systemvm from vmware and when 
it started the copy job it complained about a locked file on the vmware 
volume(?) I didn't find any locked files in the s-1177-VM vm directory on 
the vmware volume.

From the error log bellow: "Unable to create deployment, no usable volumes 
found for the VM: 1177"
Every five vmware volumes have about 50% free space, so enough space is not an 
issue...
In the case of locked file on vmware I have restarted vcenter and management 
agents on every host, so every locked files should be released.
No change.

Then I reverted to cloudstack 4.17.2 on ubuntu 22.04 on both management and 
mysql server hoping cloudstack would create the SSVM from scratch... it did 
not. Same error in the log and no S--VM created...

In Cloudstack dashboard it show  S-1177-VM as stopped, but in vmware, it's 
gone...
Everything else I have checked is running fine. Start/stop vm ++

Can it be any ubuntu 22.04 upgrade issues here?
Until I upgraded today, everything was running fine on ubuntu 18.04, Cloudstack 
4.17.2 and Mysql 5.7 Any new settings in db.properties regarding new mysql or 
ubuntu?



2023-03-29 20:58:18,866 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Found a stopped secondary storage 
V

SV: SSVM - Getting "Unable to create deployment, no usable volumes found for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

2023-03-30 Thread David Larsen
Hi Harikrishna

Yes i tried. But nothing changed. When I first stopped SSVM, everything was 
looking as normal in vmware. After it was deleted from vmware nothing happened. 

-Opprinnelig melding-
Fra: Harikrishna Patnala  
Sendt: torsdag 30. mars 2023 07:12
Til: users@cloudstack.apache.org
Emne: Re: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi David,

Did you try deleting the existing SSVM in CloudStack and let it recreate ?

Thanks,
Harikrishna

From: David Larsen 
Date: Thursday, 30 March 2023 at 1:31 AM
To: users@cloudstack.apache.org 
Subject: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi

Today i upgraded our Cloudstack (4.17.2 --> 4.18.0) , mysql (5.7--> 8) and  
ubuntu (18.04-->22.04) in production.
I thought I had tested it well in a lab... and of course  the only important 
thing I couldn't test went wrong!!
Secondary Storage VM...

At first it looked fine. I successfully upgraded console proxy system vm to 
4.18.0.
But when I tried to do the same with secondarystoragevm, stop it and wait for 
it to upgrade, Cloudstack  deleted the secondary systemvm from vmware and when 
it started the copy job it complained about a locked file on the vmware 
volume(?) I didn't find any locked files in the s-1177-VM vm directory on 
the vmware volume.

>From the error log bellow: "Unable to create deployment, no usable volumes 
>found for the VM: 1177"
Every five vmware volumes have about 50% free space, so enough space is not an 
issue...
In the case of locked file on vmware I have restarted vcenter and management 
agents on every host, so every locked files should be released.
No change.

Then I reverted to cloudstack 4.17.2 on ubuntu 22.04 on both management and 
mysql server hoping cloudstack would create the SSVM from scratch... it did 
not. Same error in the log and no S--VM created...

In Cloudstack dashboard it show  S-1177-VM as stopped, but in vmware, it's 
gone...
Everything else I have checked is running fine. Start/stop vm ++

Can it be any ubuntu 22.04 upgrade issues here?
Until I upgraded today, everything was running fine on ubuntu 18.04, Cloudstack 
4.17.2 and Mysql 5.7 Any new settings in db.properties regarding new mysql or 
ubuntu?



2023-03-29 20:58:18,866 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Found a stopped secondary storage 
VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"}, starting it.
2023-03-29 20:58:19,743 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) orchestrating VM start for 's-1177-VM' 
com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d<mailto:com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d>
 set to null
2023-03-29 20:58:19,753 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Stopped] to [Starting] with event [StartRequested]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,753 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Successfully transitioned to start state for VM instance {id: 
"1177", name: "s-1177-VM", uuid: "602280ac-a809-4ac9-b229-ea43c0ac0145", 
type="SecondaryStorageVm"} reservation id = 30f7264c-1598-45aa-a71e-b2b0f88a4519
2023-03-29 20:58:19,886 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Starting] to [Stopped] with event [OperationFailed]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,887 WARN  [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Unable to orchestrate start VM instance {id: "1177", name: 
"s-1177-VM", uuid: "602280ac-a809-4ac9-b229-ea43c0ac0145", 
type="SecondaryStorageVm"} due to [Unable to create deployment, no usable 
volumes found for the VM: 1177].
2023-03-29 20:58:19,943 WARN  [c.c.v.SystemVmLoadScanner] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Unexpected exception Unable to 
orchestrate start VM instance {id: "1177", name: "s

SV: SSVM - Getting "Unable to create deployment, no usable volumes found for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

2023-03-30 Thread David Larsen
Hi Jithin

After i sent this email yesterday, I reverted back to ubuntu 18.04/cloudstack 
4.17.2/mysql 5.7.41 from snapshots. ☹
After about five minutes, the S-1177-VM was created successfully...(?) hmm.
The only problem with the S-1177-VM now is Agent State (down). I have tried to 
restart it several times. I have not yet restarted management server.

When I checked primary and secondary volumes with 4.18.0, all volumes was 
present in cloudstack. 
Which log can I check to see if the volume allocation worked fine for SSVM?



-Opprinnelig melding-
Fra: Jithin Raju  
Sendt: torsdag 30. mars 2023 05:39
Til: users@cloudstack.apache.org
Emne: Re: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi David,

Can you check in the logs if the volume allocation worked fine for SSVM? Is 
there a record present in the volumes table?

-Jithin

From: David Larsen 
Date: Thursday, 30 March 2023 at 1:31 AM
To: users@cloudstack.apache.org 
Subject: SSVM - Getting "Unable to create deployment, no usable volumes found 
for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

Hi

Today i upgraded our Cloudstack (4.17.2 --> 4.18.0) , mysql (5.7--> 8) and  
ubuntu (18.04-->22.04) in production.
I thought I had tested it well in a lab... and of course  the only important 
thing I couldn't test went wrong!!
Secondary Storage VM...

At first it looked fine. I successfully upgraded console proxy system vm to 
4.18.0.
But when I tried to do the same with secondarystoragevm, stop it and wait for 
it to upgrade, Cloudstack  deleted the secondary systemvm from vmware and when 
it started the copy job it complained about a locked file on the vmware 
volume(?) I didn't find any locked files in the s-1177-VM vm directory on 
the vmware volume.

From the error log bellow: "Unable to create deployment, no usable volumes 
found for the VM: 1177"
Every five vmware volumes have about 50% free space, so enough space is not an 
issue...
In the case of locked file on vmware I have restarted vcenter and management 
agents on every host, so every locked files should be released.
No change.

Then I reverted to cloudstack 4.17.2 on ubuntu 22.04 on both management and 
mysql server hoping cloudstack would create the SSVM from scratch... it did 
not. Same error in the log and no S--VM created...

In Cloudstack dashboard it show  S-1177-VM as stopped, but in vmware, it's 
gone...
Everything else I have checked is running fine. Start/stop vm ++

Can it be any ubuntu 22.04 upgrade issues here?
Until I upgraded today, everything was running fine on ubuntu 18.04, Cloudstack 
4.17.2 and Mysql 5.7 Any new settings in db.properties regarding new mysql or 
ubuntu?



2023-03-29 20:58:18,866 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Found a stopped secondary storage 
VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"}, starting it.
2023-03-29 20:58:19,743 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) orchestrating VM start for 's-1177-VM' 
com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d<mailto:com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d>
 set to null
2023-03-29 20:58:19,753 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Stopped] to [Starting] with event [StartRequested]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,753 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Successfully transitioned to start state for VM instance {id: 
"1177", name: "s-1177-VM", uuid: "602280ac-a809-4ac9-b229-ea43c0ac0145", 
type="SecondaryStorageVm"} reservation id = 30f7264c-1598-45aa-a71e-b2b0f88a4519
2023-03-29 20:58:19,886 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Starting] to [Stopped] with event [OperationFailed]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,887 WARN  [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Unable to orchestrate start VM instance {id: "1177", name: 
"s-1177-VM", uu

SSVM - Getting "Unable to create deployment, no usable volumes found for the VM" after Cloudstack/Mysql/Ubuntu upgrade.

2023-03-29 Thread David Larsen

Hi

Today i upgraded our Cloudstack (4.17.2 --> 4.18.0) , mysql (5.7--> 8) and  
ubuntu (18.04-->22.04) in production.
I thought I had tested it well in a lab... and of course  the only important 
thing I couldn't test went wrong!!
Secondary Storage VM...

At first it looked fine. I successfully upgraded console proxy system vm to 
4.18.0.
But when I tried to do the same with secondarystoragevm, stop it and wait for 
it to upgrade, Cloudstack  deleted the secondary systemvm from vmware and when 
it started the copy job it complained about a locked file on the vmware 
volume(?) I didn't find any locked files in the s-1177-VM vm directory on 
the vmware volume.

>From the error log bellow: "Unable to create deployment, no usable volumes 
>found for the VM: 1177"
Every five vmware volumes have about 50% free space, so enough space is not an 
issue...
In the case of locked file on vmware I have restarted vcenter and management 
agents on every host, so every locked files should be released.
No change.

Then I reverted to cloudstack 4.17.2 on ubuntu 22.04 on both management and 
mysql server hoping cloudstack would create the SSVM from scratch... it did 
not. Same error in the log and no S--VM created...

In Cloudstack dashboard it show  S-1177-VM as stopped, but in vmware, it's 
gone...
Everything else I have checked is running fine. Start/stop vm ++

Can it be any ubuntu 22.04 upgrade issues here?
Until I upgraded today, everything was running fine on ubuntu 18.04, Cloudstack 
4.17.2 and Mysql 5.7
Any new settings in db.properties regarding new mysql or ubuntu?



2023-03-29 20:58:18,866 INFO  [o.a.c.s.SecondaryStorageManagerImpl] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Found a stopped secondary storage 
VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"}, starting it.
2023-03-29 20:58:19,743 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) orchestrating VM start for 's-1177-VM' 
com.cloud.vm.VirtualMachineProfile$Param@b66cdd7d
 set to null
2023-03-29 20:58:19,753 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Stopped] to [Starting] with event [StartRequested]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,753 DEBUG [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Successfully transitioned to start state for VM instance {id: 
"1177", name: "s-1177-VM", uuid: "602280ac-a809-4ac9-b229-ea43c0ac0145", 
type="SecondaryStorageVm"} reservation id = 30f7264c-1598-45aa-a71e-b2b0f88a4519
2023-03-29 20:58:19,886 DEBUG [c.c.c.CapacityManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} state 
transited from [Starting] to [Stopped] with event [OperationFailed]. VM's 
original host: null, new host: null, host before state transition: null
2023-03-29 20:58:19,887 WARN  [c.c.v.VirtualMachineManagerImpl] 
(Work-Job-Executor-93:ctx-c7b556c4 job-12132/job-12228 ctx-8a5aa0c5) 
(logid:4c5d9052) Unable to orchestrate start VM instance {id: "1177", name: 
"s-1177-VM", uuid: "602280ac-a809-4ac9-b229-ea43c0ac0145", 
type="SecondaryStorageVm"} due to [Unable to create deployment, no usable 
volumes found for the VM: 1177].
2023-03-29 20:58:19,943 WARN  [c.c.v.SystemVmLoadScanner] 
(secstorage-1:ctx-0dd13ec7) (logid:c5bd94b0) Unexpected exception Unable to 
orchestrate start VM instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1177].
com.cloud.utils.exception.CloudRuntimeException: Unable to orchestrate start VM 
instance {id: "1177", name: "s-1177-VM", uuid: 
"602280ac-a809-4ac9-b229-ea43c0ac0145", type="SecondaryStorageVm"} due to 
[Unable to create deployment, no usable volumes found for the VM: 1177].


Thanks

-David


SV: Mysql 5.7 --> 8 upgrade and Cloudstack 4.17.2 DB connection issues

2023-03-28 Thread David Larsen


Hi

Just an update!!

Looks like the NO_AUTO_CREATE_USER parameter for the JDBC connection URL is not 
supported in MySQL 8.0 and later versions. This parameter was deprecated in 
MySQL 5.7 and removed in MySQL 8.0.

I removed it from db.properties:
db.cloud.url.params=prepStmtCacheSize=517=true=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'=UTC

Working now!!

-David

-Opprinnelig melding-
Fra: David Larsen  
Sendt: tirsdag 28. mars 2023 15:22
Til: users@cloudstack.apache.org
Emne: Mysql 5.7 --> 8 upgrade and Cloudstack 4.17.2 DB connection issues

Hi



After mysql 5.7.41 issues with the new Cloudstack 4.18.0 release I decided to 
upgrade to mysql 8.

I'm only testing on a non production environment for now. Both servers are 
ubuntu.



have "successfully" upgraded mysql from 5.7 to 8.0.

I can connect to databases using cli and MySQL Workbench and run select 
statements from other machines

But Cloudstack cannot connect to DB anymore. Cloudstack is another server I my 
nettwork running ubuntu 18.04.

It was working fine before mysql 8 upgrade.



Thanks for any help!!





Here is the cloudstack management-server.log

2023-03-28 12:28:53,684 INFO  [o.a.c.ServerDaemon] (main:null) (logid:) Server 
configuration file found: /etc/cloudstack/management/server.properties
2023-03-28 12:28:53,694 DEBUG [c.c.u.c.EncryptionSecretKeyChecker] (main:null) 
(logid:) Encryption Type: null
2023-03-28 12:28:53,698 INFO  [o.a.c.ServerDaemon] (main:null) (logid:) 
Initializing server daemon on null, with http.enable=true, http.port=8080, 
https.enable=true, https.port=8443, context.path=/client
2023-03-28 12:28:58,320 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loading module context [bootstrap] from URL 
[jar:file:/usr/share/cloudstack-management/lib/cloudstack-4.17.2.0.jar!/META-INF/cloudstack/bootstrap/spring-bootstrap-context.xml]
2023-03-28 12:28:58,320 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loading module context [bootstrap] from URL 
[jar:file:/usr/share/cloudstack-management/lib/cloudstack-4.17.2.0.jar!/META-INF/cloudstack/bootstrap/spring-bootstrap-context-inheritable.xml]
2023-03-28 12:28:58,552 DEBUG [c.c.u.c.EncryptionSecretKeyChecker] (main:null) 
(logid:) Encryption Type: file
2023-03-28 12:28:58,665 INFO  [c.c.u.LogUtils] (main:null) (logid:) log4j 
configuration found at /etc/cloudstack/management/log4j-cloud.xml
2023-03-28 12:28:58,688 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loaded module context [bootstrap] in 352 ms
2023-03-28 12:28:58,691 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: bootstrap
2023-03-28 12:28:58,691 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   system
2023-03-28 12:28:58,692 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: core
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   allocator
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: host-allocator-random
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: planner
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   api-planner
2023-03-28 12:28:58,694 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   baremetal-planner
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   explicit-dedication
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   host-affinity
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   host-anti-affinity
2023-03-28 12:28:58,696 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   implicit-dedication
2023-03-28 12:28:58,696 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   server-planner
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   skip-heurestics
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   user-concentrated-pod
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: server-allocator
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   api
2023-03-28 12:2

Mysql 5.7 --> 8 upgrade and Cloudstack 4.17.2 DB connection issues

2023-03-28 Thread David Larsen
Hi



After mysql 5.7.41 issues with the new Cloudstack 4.18.0 release I decided to 
upgrade to mysql 8.

I'm only testing on a non production environment for now. Both servers are 
ubuntu.



have "successfully" upgraded mysql from 5.7 to 8.0.

I can connect to databases using cli and MySQL Workbench and run select 
statements from other machines

But Cloudstack cannot connect to DB anymore. Cloudstack is another server I my 
nettwork running ubuntu 18.04.

It was working fine before mysql 8 upgrade.



Thanks for any help!!





Here is the cloudstack management-server.log

2023-03-28 12:28:53,684 INFO  [o.a.c.ServerDaemon] (main:null) (logid:) Server 
configuration file found: /etc/cloudstack/management/server.properties
2023-03-28 12:28:53,694 DEBUG [c.c.u.c.EncryptionSecretKeyChecker] (main:null) 
(logid:) Encryption Type: null
2023-03-28 12:28:53,698 INFO  [o.a.c.ServerDaemon] (main:null) (logid:) 
Initializing server daemon on null, with http.enable=true, http.port=8080, 
https.enable=true, https.port=8443, context.path=/client
2023-03-28 12:28:58,320 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loading module context [bootstrap] from URL 
[jar:file:/usr/share/cloudstack-management/lib/cloudstack-4.17.2.0.jar!/META-INF/cloudstack/bootstrap/spring-bootstrap-context.xml]
2023-03-28 12:28:58,320 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loading module context [bootstrap] from URL 
[jar:file:/usr/share/cloudstack-management/lib/cloudstack-4.17.2.0.jar!/META-INF/cloudstack/bootstrap/spring-bootstrap-context-inheritable.xml]
2023-03-28 12:28:58,552 DEBUG [c.c.u.c.EncryptionSecretKeyChecker] (main:null) 
(logid:) Encryption Type: file
2023-03-28 12:28:58,665 INFO  [c.c.u.LogUtils] (main:null) (logid:) log4j 
configuration found at /etc/cloudstack/management/log4j-cloud.xml
2023-03-28 12:28:58,688 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Loaded module context [bootstrap] in 352 ms
2023-03-28 12:28:58,691 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: bootstrap
2023-03-28 12:28:58,691 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   system
2023-03-28 12:28:58,692 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: core
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   allocator
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: host-allocator-random
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: planner
2023-03-28 12:28:58,693 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   api-planner
2023-03-28 12:28:58,694 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   baremetal-planner
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   explicit-dedication
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   host-affinity
2023-03-28 12:28:58,695 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   host-anti-affinity
2023-03-28 12:28:58,696 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   implicit-dedication
2023-03-28 12:28:58,696 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   server-planner
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   skip-heurestics
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   user-concentrated-pod
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: server-allocator
2023-03-28 12:28:58,697 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy:   api
2023-03-28 12:28:58,698 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: acl-dynamic-role-based
2023-03-28 12:28:58,698 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: acl-project-role-based
2023-03-28 12:28:58,698 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: acl-static-role-based
2023-03-28 12:28:58,698 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: cloudian
2023-03-28 12:28:58,698 INFO  [o.a.c.s.m.m.i.DefaultModuleDefinitionSet] 
(main:null) (logid:) Module Hierarchy: ldap
2023-03-28 

SV: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 to 4.18.0.0

2023-03-27 Thread David Larsen
Hi 

Doing some pre upgrade checks on a non production environment, and I came aware 
off these new default settings in mysql 8. 
I guess Cloudstack still use mysql_native_password?

#Caching_sha2_password as the default
Please make sure that you double-check if your applications and proxies will 
work properly with caching_sha2_password authentication plugin as it becomes 
the default one in MySQL 8.0. Older applications might be impacted and not able 
to connect to the database. Of course, you can change this to whatever 
authentication plugin you want (like mysql_native_password for example, as it 
was the default in previous MySQL versions) so it is not a blocker by any 
means. It’s just something to remember to test before the upgrade so you won’t 
end up with MySQL 8.0 and apps that cannot connect to it unless you reconfigure 
your database to use an older authentication mechanism.

#UTF8mb4 as the default charset
This shouldn’t come as a surprise given how widely changed to UTF8 was 
discussed in the community, but that’s the fact – MySQL 8.0 comes with UTF8mb4 
charset as the default one



Here are some output from mysqlsh util.checkForServerUpgrade()

4) Usage of utf8mb3 charset
  Warning: The following objects use the utf8mb3 character set. It is
recommended to convert them to use utf8mb4 instead, for improved Unicode
support.
  More information:
https://dev.mysql.com/doc/refman/8.0/en/charset-unicode-utf8mb3.html

  cloud.account.account_name - column's default character set: utf8
  cloud.account.uuid - column's default character set: utf8
  cloud.account.state - column's default character set: utf8
  cloud.account.network_domain - column's default character set: utf8
  cloud.account_details.name - column's default character set: utf8
  cloud.account_details.value - column's default character set: utf8
  cloud.account_view.uuid - column's default character set: utf8
  cloud.account_view.account_name - column's default character set: utf8
  
  .
  all...

9) Usage of obsolete sql_mode flags
  Notice: The following DB objects have obsolete options persisted for
sql_mode, which will be cleared during upgrade to 8.0.
  More information:

https://dev.mysql.com/doc/refman/8.0/en/mysql-nutshell.html#mysql-nutshell-removals

  cloud.ADD_GUEST_OS_AND_HYPERVISOR_MAPPING - PROCEDURE uses obsolete
NO_AUTO_CREATE_USER sql_mode
  cloud.IDEMPOTENT_ADD_COLUMN - PROCEDURE uses obsolete NO_AUTO_CREATE_USER
sql_mode
  cloud_usage.IDEMPOTENT_ADD_COLUMN - PROCEDURE uses obsolete
NO_AUTO_CREATE_USER sql_mode
  cloud_usage.IDEMPOTENT_ADD_UNIQUE_INDEX - PROCEDURE uses obsolete
NO_AUTO_CREATE_USER sql_mode
  cloud_usage.IDEMPOTENT_CHANGE_COLUMN - PROCEDURE uses obsolete
NO_AUTO_CREATE_USER sql_mode
  cloud_usage.IDEMPOTENT_DROP_INDEX - PROCEDURE uses obsolete
NO_AUTO_CREATE_USER sql_mode
  global system variable sql_mode - defined using obsolete NO_AUTO_CREATE_USER
option


22) New default authentication plugin considerations
  Warning: The new default authentication plugin 'caching_sha2_password' offers
more secure password hashing than previously used 'mysql_native_password'
(and consequent improved client connection authentication). However, it also
has compatibility implications that may affect existing MySQL 
installations. 
If your MySQL installation must serve pre-8.0 clients and you encounter
compatibility issues after upgrading, the simplest way to address those
issues is to reconfigure the server to revert to the previous default
authentication plugin (mysql_native_password). For example, use these lines
in the server option file:

[mysqld]
default_authentication_plugin=mysql_native_password

However, the setting should be viewed as temporary, not as a long term or
permanent solution, because it causes new accounts created with the setting
in effect to forego the improved authentication security.
If you are using replication please take time to understand how the
authentication plugin changes may impact you.

Errors:   0
Warnings: 1503
Notices:  7

NOTE: No fatal errors were found that would prevent an upgrade, but some 
potential issues were detected. Please ensure that the reported issues are not 
significant before upgrading.
 MySQL  localhost:3306 ssl  JS >


-David

-Opprinnelig melding-
Fra: Wei ZHOU  
Sendt: mandag 27. mars 2023 10:35
Til: users@cloudstack.apache.org
Emne: Re: SQL error and "can't upgrade database" when I try to upgrade CS 
4.17.1.0 to 4.18.0.0

Hi David,

There is no special setting for mysql upgrade.

You'd better back up the database and then upgrade mysql. It would be good to 
test the upgrade on a test server before changes on production.

-Wei

On Mon, 27 Mar 2023 at 09:58, David Larsen  wrote:

> Hi Wei
>
> Thanks for the link. I will keep an eye on it.
>
> Strang

SV: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 to 4.18.0.0

2023-03-27 Thread David Larsen
Hi Wei

Thanks for the link. I will keep an eye on it. 

Strange problem... I'm still stuck with mysql 5.7.41 and CS 4.17.2 since the 
mysql 8 upgrade was not successful. I had to revert... 
I didn't have so much time on friday to investigate further, so I will look 
more into it today.

By the way... Any obvious traps to fell into regarding Cloudstack and upgrade 
to Mysql 8? 
Any changes in db.properties files or any connectors?

Thanks 

-David



-Opprinnelig melding-
Fra: Wei ZHOU  
Sendt: fredag 24. mars 2023 22:20
Til: users@cloudstack.apache.org
Emne: Re: SQL error and "can't upgrade database" when I try to upgrade CS 
4.17.1.0 to 4.18.0.0

Hi,
Please keep an eye on
https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Fcloudstack%2Fissues%2F7358=05%7C01%7CDavid.Larsen%40adcom.no%7C9f883b0268be4169ec5708db2cad9c68%7C1dd023eed2894f208926463c9b991b5f%7C0%7C0%7C638152896393257998%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C=BkCodMPt25eSHiLwb2kWVvecXD6OeIy1zNybkso8A2c%3D=0

-Wei


On Friday, 24 March 2023, David Larsen  wrote:

> Hi
>
> I’m running CS 4.17.1.0 on ubuntu 18.04 and MySQL 5.7.41, and tried to 
> upgrade to 4.18.0.0
>
> Please see log bellow for details regarding sql error.
>
>
> 2023-03-24 15:07:42,669 DEBUG [c.c.u.d.ScriptRunner] (main:null) 
> (logid:) CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.vm_template', 
> 'user_data_id', 'bigint unsigned DEFAULT NULL COMMENT "id of the us
>er data"')
> 2023-03-24 15:07:43,075 DEBUG [c.c.u.d.ScriptRunner] (main:null) 
> (logid:) CALL 
> `cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template',
> 'user_data', 'id')
> 2023-03-24 15:07:43,213 ERROR [c.c.u.d.ScriptRunner] (main:null) 
> (logid:) Error executing: CALL 
> `cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template',
> 'user_data', 'id')
> 2023-03-24 15:07:43,214 ERROR [c.c.u.d.ScriptRunner] (main:null) 
> (logid:)
> java.sql.SQLIntegrityConstraintViolationException: Can't write; 
> duplicate key in table '#sql-500_158'
> 2023-03-24 15:07:43,216 ERROR [c.c.u.DatabaseUpgradeChecker] 
> (main:null)
> (logid:) Unable to execute upgrade script
> java.sql.SQLIntegrityConstraintViolationException: Can't write; 
> duplicate key in table '#sql-500_158'
> at com.cloud.utils.db.ScriptRunner.runScript(
> ScriptRunner.java:185)
> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
> at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(
> DatabaseUpgradeChecker.java:226)
> at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(
> DatabaseUpgradeChecker.java:310)
> at com.cloud.upgrade.DatabaseUpgradeChecker.check(
> DatabaseUpgradeChecker.java:401)
> at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.
> java:64)
> at org.apache.cloudstack.spring.lifecycle.
> CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
> at org.springframework.context.support.DefaultLifecycleProcessor.
> doStart(DefaultLifecycleProcessor.java:178)
> at org.springframework.context.support.DefaultLifecycleProcessor.
> access$200(DefaultLifecycleProcessor.java:54)
> at 
> org.springframework.context.support.DefaultLifecycleProcessor$
> LifecycleGroup.start(DefaultLifecycleProcessor.java:356)
> at java.base/java.lang.Iterable.forEach(Iterable.java:75)
> at org.springframework.context.support.DefaultLifecycleProcessor.
> startBeans(DefaultLifecycleProcessor.java:155)
> at org.springframework.context.support.DefaultLifecycleProcessor.
> onRefresh(DefaultLifecycleProcessor.java:123)
> at org.springframework.context.support.AbstractApplicationContext.
> finishRefresh(AbstractApplicationContext.java:935)
> at org.springframework.context.support.AbstractApplicationContext.
> refresh(AbstractApplicationContext.java:586)
> at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.
> java:144)
> at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
> at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
> at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
> at org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
> at org.apache.cloudstack.spri

SV: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 to 4.18.0.0

2023-03-24 Thread David Larsen

Hi Gary

Thanks for update. I will try to upgrade mysql to 8.0 then.



-David



Fra: Gary Dixon 
Sendt: fredag 24. mars 2023 17:37
Til: users@cloudstack.apache.org
Emne: RE: SQL error and "can't upgrade database" when I try to upgrade CS 
4.17.1.0 to 4.18.0.0


Somebody else recently posted about this issue and resolved it by updating 
their MySql that was also on v5.7.41 - they didn't specify what version they 
updated MySql to however
Gary Dixon​
Senior Technical Consultant
T:  +44 161 537 4990
E:  vms@quadris‑support.com
W: www.quadris.co.uk<http://www.quadris.co.uk>
[cid:image552174.png@F2EB7DBA.3861FD3F]
The information contained in this e-mail from Quadris may be confidential and 
privileged for the private use of the named recipient.  The contents of this 
e-mail may not necessarily represent the official views of Quadris.  If you 
have received this information in error you must not copy, distribute or take 
any action or reliance on its contents.  Please destroy any hard copies and 
delete this message.
-Original Message-----
From: David Larsen mailto:david.lar...@adcom.no>>
Sent: Friday, March 24, 2023 4:27 PM
To: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org>
Subject: SV: SQL error and "can't upgrade database" when I try to upgrade CS 
4.17.1.0 to 4.18.0.0

Update:
I reverted to 4.17.1.0 snapshot and successfully upgraded to 4.17.2.0 without 
any issues.
I will try upgrade to 4.18.0 from 4.17.2.0 later.

Med vennlig hilsen

David Larsen
Senior systemkonsulent


ADCOM MOLDE, IT Data AS
Fabrikkvegen 13  | 6415 Molde
Mobil: 959 48 308 | Sentralbord: 71 25 06 40
david.lar...@adcom.no<mailto:david.lar...@adcom.no> | 
https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.adcom.no%2F=05%7C01%7CGary.Dixon%40quadris.co.uk%7C68fd5fbd03f147134c6008db2c84b008%7Cf1d6abf3d3b44894ae16db0fb93a96a2%7C0%7C0%7C638152720630391311%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C=2srpXA2d5XwQHLEW9bT%2BPwgtz5RCzAqI5et%2BYVX7qKE%3D=0



Følg oss på sosiale medier:
• Tenk på miljøet før du skriver ut denne eposten


-----Opprinnelig melding-
Fra: David Larsen mailto:david.lar...@adcom.no>>
Sendt: fredag 24. mars 2023 15:33
Til: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org>
Emne: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 
to 4.18.0.0

Hi

I’m running CS 4.17.1.0 on ubuntu 18.04 and MySQL 5.7.41, and tried to upgrade 
to 4.18.0.0

Please see log bellow for details regarding sql error.


2023-03-24 15:07:42,669 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.vm_template', 'user_data_id', 'bigint 
unsigned DEFAULT NULL COMMENT "id of the us er data"')
2023-03-24 15:07:43,075 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 'user_data', 'id')
2023-03-24 15:07:43,213 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) Error 
executing: CALL `cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 
'user_data', 'id')
2023-03-24 15:07:43,214 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) 
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
2023-03-24 15:07:43,216 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) 
(logid:) Unable to execute upgrade script
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:226)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:310)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:401)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.java:64)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:178)
at 
org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:356)
at java.base/java.lang.Iterable.forEach(Iterable.java:75)
at 
org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:155)
at 
org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:123)
at 
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:935)
at 
org.springframework.context.su

SV: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 to 4.18.0.0

2023-03-24 Thread David Larsen
Update: 
I reverted to 4.17.1.0 snapshot and successfully upgraded to 4.17.2.0 without 
any issues.
I will try upgrade to 4.18.0 from 4.17.2.0 later.

Med vennlig hilsen

David Larsen 
Senior systemkonsulent


ADCOM MOLDE, IT Data AS
Fabrikkvegen 13  | 6415 Molde 
Mobil: 959 48 308 | Sentralbord: 71 25 06 40
david.lar...@adcom.no | www.adcom.no 

    

Følg oss på sosiale medier: 
 Tenk på miljøet før du skriver ut denne eposten


-Opprinnelig melding-
Fra: David Larsen  
Sendt: fredag 24. mars 2023 15:33
Til: users@cloudstack.apache.org
Emne: SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 
to 4.18.0.0

Hi

I’m running CS 4.17.1.0 on ubuntu 18.04 and MySQL 5.7.41, and tried to upgrade 
to 4.18.0.0

Please see log bellow for details regarding sql error.


2023-03-24 15:07:42,669 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.vm_template', 'user_data_id', 'bigint 
unsigned DEFAULT NULL COMMENT "id of the us   er 
data"')
2023-03-24 15:07:43,075 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 'user_data', 'id')
2023-03-24 15:07:43,213 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) Error 
executing: CALL `cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 
'user_data', 'id')
2023-03-24 15:07:43,214 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) 
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
2023-03-24 15:07:43,216 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) 
(logid:) Unable to execute upgrade script
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:226)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:310)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:401)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.java:64)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:178)
at 
org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:356)
at java.base/java.lang.Iterable.forEach(Iterable.java:75)
at 
org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:155)
at 
org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:123)
at 
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:935)
at 
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:586)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
at 
org.apache.cloudstack.spring.module.factory.ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.init(CloudStackSpringContext.java:70)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.(CloudStackSpringContext.java:57)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.(CloudStackSpringContext.java:61)
at 
org.apache.cloudstack.spring.module.web.CloudStackContextLoaderListener.contextInitialized(CloudStackContextLo

SQL error and "can't upgrade database" when I try to upgrade CS 4.17.1.0 to 4.18.0.0

2023-03-24 Thread David Larsen
Hi

I’m running CS 4.17.1.0 on ubuntu 18.04 and MySQL 5.7.41, and tried to upgrade 
to 4.18.0.0

Please see log bellow for details regarding sql error.


2023-03-24 15:07:42,669 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.vm_template', 'user_data_id', 'bigint 
unsigned DEFAULT NULL COMMENT "id of the us   er 
data"')
2023-03-24 15:07:43,075 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) CALL 
`cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 'user_data', 'id')
2023-03-24 15:07:43,213 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) Error 
executing: CALL `cloud`.`IDEMPOTENT_ADD_FOREIGN_KEY`('cloud.vm_template', 
'user_data', 'id')
2023-03-24 15:07:43,214 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) 
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
2023-03-24 15:07:43,216 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) 
(logid:) Unable to execute upgrade script
java.sql.SQLIntegrityConstraintViolationException: Can't write; duplicate key 
in table '#sql-500_158'
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:226)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:310)
at 
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:401)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.java:64)
at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:178)
at 
org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:54)
at 
org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:356)
at java.base/java.lang.Iterable.forEach(Iterable.java:75)
at 
org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:155)
at 
org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:123)
at 
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:935)
at 
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:586)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContext(DefaultModuleDefinitionSet.java:144)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet$2.with(DefaultModuleDefinitionSet.java:121)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:244)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:249)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.withModule(DefaultModuleDefinitionSet.java:232)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.loadContexts(DefaultModuleDefinitionSet.java:116)
at 
org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.load(DefaultModuleDefinitionSet.java:78)
at 
org.apache.cloudstack.spring.module.factory.ModuleBasedContextFactory.loadModules(ModuleBasedContextFactory.java:37)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.init(CloudStackSpringContext.java:70)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.(CloudStackSpringContext.java:57)
at 
org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.(CloudStackSpringContext.java:61)
at 
org.apache.cloudstack.spring.module.web.CloudStackContextLoaderListener.contextInitialized(CloudStackContextLoaderListener.java:52)
at 
org.eclipse.jetty.server.handler.ContextHandler.callContextInitialized(ContextHandler.java:1073)
at 
org.eclipse.jetty.servlet.ServletContextHandler.callContextInitialized(ServletContextHandler.java:572)
at 
org.eclipse.jetty.server.handler.ContextHandler.contextInitialized(ContextHandler.java:1002)
at 
org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:765)
at 
org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:379)
at 
org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1449)
at 
org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1414)
at 

Redirect HTTP 8080 to HTTPS 8443 on Cloudstack 4.17.1.0

2022-11-18 Thread David Larsen
Hi

We are using Cloudstack 4.17.1.0.
Https://host.domain.com:8443 works fine.

I followed to steps below to redirect http 8080 to https 8443 with no luck
Is there another way to do this in 4.17.1.0?
Hope so... :-)



For auto redirection from 8080 to 8443, Add below content in 
'/usr/share/cloudstack-management/webapp/WEB-INF/web.xml' file at line 22




Everything in the webapp

/*





CONFIDENTIAL












...

8443






Restart the management service
systemctl restart cloudstack-management


Best regards
David Larsen


Re: Cloudstack user logins with 2FA and Google Authenticator

2022-11-18 Thread David Larsen
Hi Harikrishna

Thanks for info. 
We will wait for 4.18 release then.

David Larsen 


-Opprinnelig melding-
Fra: Harikrishna Patnala  
Sendt: fredag 18. november 2022 08:36
Til: users@cloudstack.apache.org
Emne: Re: Cloudstack user logins with 2FA and Google Authenticator

Hi David,

2FA framework and plugin is under development and planning to make it in 4.18 
release. It is not available in 4.17.1.
You can find some details about the feature here at 
https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fcwiki.apache.org%2Fconfluence%2Fdisplay%2FCLOUDSTACK%2F2FA%2BFramework%2Band%2BPluginsdata=05%7C01%7CDavid.Larsen%40adcom.no%7Ccb18761196144380500408dac937a803%7C1dd023eed2894f208926463c9b991b5f%7C0%7C0%7C638043538125138827%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=nVI3%2F%2F6oJRDSsOV1e7OPMWE2KEZNpxMvWZRkXbekQU8%3Dreserved=0

Regards,
Harikrishna

From: David Larsen 
Date: Thursday, 17 November 2022 at 8:19 PM
To: users@cloudstack.apache.org 
Subject: Cloudstack user logins with 2FA and Google Authenticator

Hi

We are currently working on how to integrate Cloudstack (4.17.1.0) logins with 
Google and Google  authenticator.
Is there any “this is how you do it” documents out there for Cloudstack. I 
found some info related to it , but no luck yet… ☹

I saw the “2FA Framework and Plugins” document from the 4.17 design documents 
by Rohit. Is this plugin deployed in 4.17.1.0?

Do we have to use SAML2 to make this work?
And if so, how?


Any help pointing me in the right direction will help us a lot.


Best regards
David Larsen

 



Cloudstack user logins with 2FA and Google Authenticator

2022-11-17 Thread David Larsen

Hi

We are currently working on how to integrate Cloudstack (4.17.1.0) logins with 
Google and Google  authenticator.
Is there any “this is how you do it” documents out there for Cloudstack. I 
found some info related to it , but no luck yet… ☹

I saw the “2FA Framework and Plugins” document from the 4.17 design documents 
by Rohit. Is this plugin deployed in 4.17.1.0?

Do we have to use SAML2 to make this work?
And if so, how?


Any help pointing me in the right direction will help us a lot.


Best regards
David Larsen


cloud_usage.cloud_usage DB not updated after upgrading Cloudstack from 4.15 to 4.16.1

2022-06-07 Thread David Larsen

Hi

Any big changes in Cloudstack usage DB  since cloud_usage.cloud_usage is not 
updated since we upgraded?
Other usage db like Cloud_usage.usage_vm are updated with latest time/date...

Found this info on ShapeBlue:
Apache CloudStack 4.16.1.0 Release - Deep Dive
..
Database Structure Improvements
This improvement adds the missing primary keys for some of the tables on the 
'cloud' and 'cloud_usage' schema in the CloudStack database. This enables 
better MySQL performance and replication.
..


-David




SV: Cannot delete image store with active templates backup!

2022-05-09 Thread David Larsen
Hi
Just an update... 
I upgraded Cloudstack (4.16.1.0) this weekend. Then I successfully deleted my 
old secondary storage. 

-David


-Opprinnelig melding-
Fra: David Larsen  
Sendt: onsdag 4. mai 2022 15:16
Til: users@cloudstack.apache.org
Emne: Cannot delete image store with active templates backup!

Hi

I'm trying to delete a old Secondary Storage from Cloudstack and get this 
message:
"Cannot delete image store with active templates backup!"

I have successfully used the "Migrate data from Image store" to another 
Secondary Store NFS server, resulting in the old Secondary Storage changed to 
"Read Only"
Are there still active templates when it is migrated?

How can I proceed to remove the old Secondary Storage?

I'm running Cloudstack 4.15 and vsphere/vcenter 6.7. Old Secondary storage 
running on Centos and the new is running on Ubuntu


-David


Cannot delete image store with active templates backup!

2022-05-04 Thread David Larsen
Hi

I'm trying to delete a old Secondary Storage from Cloudstack and get this 
message:
"Cannot delete image store with active templates backup!"

I have successfully used the "Migrate data from Image store" to another 
Secondary Store NFS server, resulting in the old Secondary Storage changed to 
"Read Only"
Are there still active templates when it is migrated?

How can I proceed to remove the old Secondary Storage?

I'm running Cloudstack 4.15 and vsphere/vcenter 6.7. Old Secondary storage 
running on Centos and the new is running on Ubuntu


-David


SV: Request Failed (530) - Cannot delete pool Primary as there are associated non-destroyed vols for this pool

2022-04-27 Thread David Larsen
Hi Pearl



Spot on!!  



There was two volumes for old deleted virtual routers hanging in there...

I have successfully deleted Primary storage now.



Thank you 



Med vennlig hilsen



David Larsen

Senior systemkonsulent





ADCOM MOLDE, IT Data AS

Fabrikkvegen 13  | 6415 Molde

david.lar...@adcom.no | www.adcom.no







-Opprinnelig melding-
Fra: Pearl d'Silva 
Sendt: onsdag 27. april 2022 13:11
Til: users@cloudstack.apache.org
Emne: Re: Request Failed (530) - Cannot delete pool Primary as there are 
associated non-destroyed vols for this pool



Hi David,



The error message indicates that there are some volumes on the primary store 
that you are attempting to remove in the database. You can validate it by using:

select * from volumes where pool_id =  and removed is null;



If you have validated that the volumes returned by the above query have been 
either deleted or migrated, then you can mark them as removed in the db and 
proceed with removing the storage pool.



Thanks,

Pearl





From: David Larsen mailto:david.lar...@adcom.no>>

Sent: Wednesday, April 27, 2022 4:23 PM

To: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org> 
mailto:users@cloudstack.apache.org>>

Subject: Request Failed (530) - Cannot delete pool Primary as there are 
associated non-destroyed vols for this pool





Hi







We are replacing our old datastore with a newer and faster storage.



I have successfully created new volumes and successfully migrated every 
instance/volum, systemVM’s and Virtual routers to new volumes.



We have five volumes on the old storage system and five on the new storage 
system (vmware vmfs volumes).



After everything was migrated, we put the old volumes successfully in 
maintenance mode. The next step is to delete them from Cloudstack. We have 
successfully deleted volume2, volume3, volume4 and volume 5, but not volume1. 
When we try to delete it, we get this message:



“Request Failed (530) Cannot delete pool Primary as there are associated 
non-destroyed vols for this pool”







We have checked volume1 for any volume files, but we can’t find any. Found a 
few very old .vmdk files in a folder called “fcd”, but can’t find any reference 
to them in cloudstack…(?)



Volume1 is the first vmfs volume ever created on our Cloudstack solution and is 
the only vmfs5 volume left.







Anything we have missed?







We are running Cloudstack 4.15, vcenter/vsphere 6.7







Thanks ??







Med vennlig hilsen







David Larsen

Senior systemkonsulent







[cid:image001.png@01D85A32.9061E8F0]



ADCOM MOLDE, IT Data AS

Fabrikkvegen 13  | 6415 Molde

Mobil: 959 48 308 | Sentralbord: 71 25 06 40 
david.lar...@adcom.no<mailto:david.lar...@adcom.no<mailto:david.lar...@adcom.no%3cmailto:david.lar...@adcom.no>>
 | 
https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.adcom.no%2Fdata=05%7C01%7C%7Cc2689bedda5e4093f32708da283eaf9c%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637866546962327237%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=RJlSyXmDhMHFYqgPHrAxaQvDr3kwM5c1J6QgLEMSsi8%3Dreserved=0<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.adcom.no%2Fdata=05%7C01%7C%7Cc2689bedda5e4093f32708da283eaf9c%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637866546962327237%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=RJlSyXmDhMHFYqgPHrAxaQvDr3kwM5c1J6QgLEMSsi8%3Dreserved=0<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.adcom.no%2Fdata=05%7C01%7C%7Cc2689bedda5e4093f32708da283eaf9c%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637866546962327237%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=RJlSyXmDhMHFYqgPHrAxaQvDr3kwM5c1J6QgLEMSsi8%3Dreserved=0%3chttps://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.adcom.no%2Fdata=05%7C01%7C%7Cc2689bedda5e4093f32708da283eaf9c%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637866546962327237%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=RJlSyXmDhMHFYqgPHrAxaQvDr3kwM5c1J6QgLEMSsi8%3Dreserved=0>>







[Miljøfyrtårn][cid:image003.png@01D85A32.9061E8F0]







Følg oss på sosiale medier: [Facebook icon] 
<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.facebook.com%2Fadcommolde%2Fdata=05%7C01%7C%7Cc2689bedda5e4093f32708da283eaf9c%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637866546962327237%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7Csdata=G9g%2FJ2gx%2BQd3AZhdW2SqJMpwiLzJzrVJmF9yQt3ZCnI%3Dreserved=0>
 [LinkedIn icon] 
<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.linkedin.com%2Fcompany%2F10249752%3Ftrk%3Dtyah%26trkInf

Request Failed (530) - Cannot delete pool Primary as there are associated non-destroyed vols for this pool

2022-04-27 Thread David Larsen
Hi

We are replacing our old datastore with a newer and faster storage.
I have successfully created new volumes and successfully migrated every 
instance/volum, systemVM’s and Virtual routers to new volumes.
We have five volumes on the old storage system and five on the new storage 
system (vmware vmfs volumes).
After everything was migrated, we put the old volumes successfully in 
maintenance mode. The next step is to delete them from Cloudstack. We have 
successfully deleted volume2, volume3, volume4 and volume 5, but not volume1. 
When we try to delete it, we get this message:
“Request Failed (530) Cannot delete pool Primary as there are associated 
non-destroyed vols for this pool”

We have checked volume1 for any volume files, but we can’t find any. Found a 
few very old .vmdk files in a folder called “fcd”, but can’t find any reference 
to them in cloudstack…(?)
Volume1 is the first vmfs volume ever created on our Cloudstack solution and is 
the only vmfs5 volume left.

Anything we have missed?

We are running Cloudstack 4.15, vcenter/vsphere 6.7

Thanks 

Med vennlig hilsen

David Larsen
Senior systemkonsulent

[cid:image001.png@01D85A32.9061E8F0]
ADCOM MOLDE, IT Data AS
Fabrikkvegen 13  | 6415 Molde
Mobil: 959 48 308 | Sentralbord: 71 25 06 40
david.lar...@adcom.no<mailto:david.lar...@adcom.no> | 
www.adcom.no<http://www.adcom.no/>

[Miljøfyrtårn][cid:image003.png@01D85A32.9061E8F0]

Følg oss på sosiale medier: [Facebook icon] 
<https://www.facebook.com/adcommolde/> [LinkedIn icon] 
<https://www.linkedin.com/company/10249752?trk=tyah=clickedVertical%3Acompany%2CclickedEntityId%3A10249752%2Cidx%3A2-1-2%2CtarId%3A1449043739552%2Ctas%3Aadcom%20molde>
P Tenk på miljøet før du skriver ut denne eposten




RE: systemvm-vmware-4.15.1 template - Did not find a guest OS with type otherLinux64Guest

2021-10-16 Thread David Larsen
Hi Wei,


My configuration:
Cloudstack 4.15

Vmware:
Vcenter: latest 6.7
Vsphere hosts: vsphere 6.7 u1

When we upgraded from 4.13 to 4.15 it was the same issue with systemvm 
template. To complete the upgrade to 4.15, I manualy changed os type for 
systemvm template in DB. But why...??? I know there is some new feature about 
vmware and ova import, but it don't work for systemvm templates in my setup...

-David

Sendt fra min Galaxy



 Opprinnelig melding 
Fra: Wei ZHOU 
Dato: 15.10.2021 12:30 (GMT+01:00)
Til: users 
Emne: Re: systemvm-vmware-4.15.1 template - Did not find a guest OS with type 
otherLinux64Guest

What is your current cloudstack version ?
Could you please share more details?

-Wei

On Fri, 15 Oct 2021 at 11:59, David Larsen  wrote:

> Hi
>
> We use vcenter/vsphere 6.7
>
>
>
> Sendt fra min Galaxy
>
>
>
>  Opprinnelig melding 
> Fra: Wei ZHOU 
> Dato: 15.10.2021 09:18 (GMT+01:00)
> Til: users 
> Emne: Re: systemvm-vmware-4.15.1 template - Did not find a guest OS with
> type otherLinux64Guest
>
> Hi David,
>
> Which version of vmware do you use ?
>
> -Wei
>
> On Thu, 14 Oct 2021 at 16:20, David Larsen  wrote:
>
> > Hi
> >
> > I have just tried to install systemvm-vmware-4.15.1 template to prepare
> > for cloudstack 4.15.2 upgrade. When I choose Hypervisor: VMware, I cannot
> > choos OS Type afterwards.
> > The template never become "Ready"
> >
> > The Cloudstack system-vm upgrade documentation step 6 it says:
> > "Watch the screen to be sure that the template downloads successfully and
> > enters the READY state. Do not proceed until this is successful"
> >
> > This is the template status  after four hours...
> > Zone:
> > Status: Did not find a guest OS with type otherLinux64Guest
> > Ready: No
> >
> > Do I have to change OS-Type directly in th DB or is it something else I
> > have completely missed?
> > Creating system-vm templates used to be so easy...
> >
> >
>


RE: systemvm-vmware-4.15.1 template - Did not find a guest OS with type otherLinux64Guest

2021-10-15 Thread David Larsen
Hi

We use vcenter/vsphere 6.7



Sendt fra min Galaxy



 Opprinnelig melding 
Fra: Wei ZHOU 
Dato: 15.10.2021 09:18 (GMT+01:00)
Til: users 
Emne: Re: systemvm-vmware-4.15.1 template - Did not find a guest OS with type 
otherLinux64Guest

Hi David,

Which version of vmware do you use ?

-Wei

On Thu, 14 Oct 2021 at 16:20, David Larsen  wrote:

> Hi
>
> I have just tried to install systemvm-vmware-4.15.1 template to prepare
> for cloudstack 4.15.2 upgrade. When I choose Hypervisor: VMware, I cannot
> choos OS Type afterwards.
> The template never become "Ready"
>
> The Cloudstack system-vm upgrade documentation step 6 it says:
> "Watch the screen to be sure that the template downloads successfully and
> enters the READY state. Do not proceed until this is successful"
>
> This is the template status  after four hours...
> Zone:
> Status: Did not find a guest OS with type otherLinux64Guest
> Ready: No
>
> Do I have to change OS-Type directly in th DB or is it something else I
> have completely missed?
> Creating system-vm templates used to be so easy...
>
>


systemvm-vmware-4.15.1 template - Did not find a guest OS with type otherLinux64Guest

2021-10-14 Thread David Larsen
Hi

I have just tried to install systemvm-vmware-4.15.1 template to prepare for 
cloudstack 4.15.2 upgrade. When I choose Hypervisor: VMware, I cannot choos OS 
Type afterwards.
The template never become "Ready"

The Cloudstack system-vm upgrade documentation step 6 it says: 
"Watch the screen to be sure that the template downloads successfully and 
enters the READY state. Do not proceed until this is successful"

This is the template status  after four hours...
Zone:   
Status: Did not find a guest OS with type otherLinux64Guest 
Ready: No

Do I have to change OS-Type directly in th DB or is it something else I have 
completely missed?
Creating system-vm templates used to be so easy...



SV: Dynamic Roles and user roles in command.properties

2021-10-06 Thread David Larsen
efault=3306,
help="Host or IP of the MySQL server")
parser.add_option("-f", "--properties-file", action="store", type="string", 
dest="commandsfile", default="/etc/cloudstack/management/commands.properties",
help="The commands.properties file")
parser.add_option("-D", "--default", action="store_true", 
dest="defaultRules", default=False,
help="")
parser.add_option("-d", "--dryrun", action="store_true", dest="dryrun", 
default=False,
help="Dry run and debug operations this tool will 
perform")
(options, args) = parser.parse_args()

print("Apache CloudStack Role Permission Migration Tool")
print("(c) Apache CloudStack Authors and the ASF, under the Apache License, 
Version 2.0\n")

global dryrun
if options.dryrun:
dryrun = True

conn = mysql.connector.connect(
host=options.host,
user=options.user,
passwd=options.password,
port=int(options.port),
db=options.db)

if options.defaultRules:
print("Applying the default role permissions, ignoring any provided 
properties files(s).")
enableDynamicApiChecker(conn)
sys.exit(0)

if not os.path.isfile(options.commandsfile):
print("Provided commands.properties cannot be accessed or does not 
exist.")
print("Please check passed options, or run only with --default option 
to use the default role permissions.")
sys.exit(1)

while True:
choice = input("Running this migration tool will remove any " +
   "default-role permissions from 
cloud.role_permissions. " +
   "Do you want to continue? [y/N]").lower()
if choice == 'y':
break
else:
print("Aborting!")
sys.exit(1)

# Generate API to permission octet map
apiMap = {}
with open(options.commandsfile) as f:
for line in f.readlines():
if not line or line == '' or line == '\n' or line == '\r\n' or 
line.startswith('#'):
continue
name, value = line.split('=')
apiMap[name.strip()] = value.strip().split(';')[-1]

# Rename and deprecate old commands.properties file
if not dryrun:
os.rename(options.commandsfile, options.commandsfile + '.deprecated')
print("The commands.properties file has been deprecated and moved at: " + 
options.commandsfile + '.deprecated')

# Truncate any rules in cloud.role_permissions table
runSql(conn, "DELETE FROM `cloud`.`role_permissions` WHERE `role_id` in 
(1,2,3,4);")

# Migrate rules from commands.properties to cloud.role_permissions
migrateApiRolePermissions(apiMap, conn)

enableDynamicApiChecker(conn)

if __name__ == '__main__':
main()



David Larsen 

-Opprinnelig melding-
Fra: Daan Hoogland  
Sendt: onsdag 6. oktober 2021 10.29
Til: users 
Emne: Re: Dynamic Roles and user roles in command.properties

David,
Only createSnapshotFromVMSnapshot and moveNetworkAclItem, does explain that 
users can not log in, after logging in a lot of list* APIs are executed.
The roles you have, are the default set of roles and the "User" should contain 
all that is needed to have a normal log on working.
I have no idea why and how the conversion failed, but at least all entries with 
=15 should be in that role and then probably some new APIs as well.
I didn't quite get if "root admin" can log in fine, for them there should be an 
entry * - allow.

I think you have three options:
- 1. debug the conversion script
- 2. install a clean sheet ACS in a test env and copy the roles data from that
- 3. do the thing you so dread (sorry) and fill the entries in the DB

maybe a combination of the three will work as well.

regards,


On Wed, Oct 6, 2021 at 9:46 AM David Larsen  wrote:

> Hi Daan.
>
> Our complete commands.properties are listed below. I have never 
> changed it.
>
> When I tried the migrate script with the -D option, no user can log in 
> completely. After they log in, it shows "Discovering features..." or 
> something like that... Don't remember the exact words.
> Global Admin users have full access.
>
> When I look into the Roles section in Cloudstack, user role has  two
> rules:
> createSnapshotFromVMSnapshot - allow
> moveNetworkAclItem - allow
>
>
> If the migrate script don't work, what are my options?
> Do I have to go through the commands.properties file and add every 
> dynamic roles manually?
> Hope not...
>
> From the roles section in Cloudstack, I ha

SV: Dynamic Roles and user roles in command.properties

2021-10-06 Thread David Larsen
ot=15

 Baremetal commands
addBaremetalHost=1
addBaremetalPxeKickStartServer=1
addBaremetalPxePingServer=1
addBaremetalDhcp=1
listBaremetalDhcp=1
listBaremetalPxeServers=1
addBaremetalRct=1
deleteBaremetalRct=1
listBaremetalRct=1

 UCS commands
addUcsManager=1
listUcsManagers=1
listUcsProfiles=1
listUcsBlades=1
associateUcsProfileToBlade=1
removedeleteUcsManager=1

 New Load Balancer commands
createLoadBalancer=15
listLoadBalancers=15
deleteLoadBalancer=15
updateLoadBalancer=15

#Internal Load Balancer Element commands
configureInternalLoadBalancerElement=7
createInternalLoadBalancerElement=7
listInternalLoadBalancerElements=7


 Affinity group commands
createAffinityGroup=15
deleteAffinityGroup=15
listAffinityGroups=15
updateVMAffinityGroup=15
listAffinityGroupTypes=15

 Cisco Vnmc commands
addCiscoVnmcResource=1
deleteCiscoVnmcResource=1
listCiscoVnmcResources=1

 Cisco Asa1000v commands
addCiscoAsa1000vResource=1
deleteCiscoAsa1000vResource=1
listCiscoAsa1000vResources=1

 portable public IP commands
createPortableIpRange=1
deletePortableIpRange=1
listPortableIpRanges=1

 Internal LB VM commands
stopInternalLoadBalancerVM=1
startInternalLoadBalancerVM=1
listInternalLoadBalancerVMs=1

### Network Isolation methods listing
listNetworkIsolationMethods=1

 Dedicated Resource commands
dedicateZone=1
dedicatePod=1
dedicateCluster=1
dedicateHost=1
releaseDedicatedZone=1
releaseDedicatedPod=1
releaseDedicatedCluster=1
releaseDedicatedHost=1
listDedicatedZones=1
listDedicatedPods=1
listDedicatedClusters=1
listDedicatedHosts=1

### LDAP
listLdapConfigurations=15
addLdapConfiguration=3
deleteLdapConfiguration=3
listLdapUsers=3
ldapCreateAccount=3
importLdapUsers=3
linkDomainToLdap=3


 juniper-contrail commands
createServiceInstance=1

### OpenDaylight plugin commands
addOpenDaylightController=1
deleteOpenDaylightController=1
listOpenDaylightControllers=1

### GloboDNS commands
addGloboDnsHost=1

### volume/template post upload
getUploadParamsForVolume=15
getUploadParamsForTemplate=15

### Quota Service
quotaStatement=15
quotaBalance=15
quotaSummary=15
quotaUpdate=1
quotaTariffList=15
quotaTariffUpdate=1
quotaCredits=1
quotaEmailTemplateList=1
quotaEmailTemplateUpdate=1
quotaIsEnabled=15




David Larsen 

-Opprinnelig melding-
Fra: David Larsen  
Sendt: mandag 4. oktober 2021 17.46
Til: users@cloudstack.apache.org
Emne: SV: Dynamic Roles and user roles in command.properties

Hi Daan.

Thanks for your quick reply. 
I see.., 15 is user allowed.  didn't read the description good enough 
I have never created any roles.  I tried the -D option with 
migrate-dynamicroles.py 

Med vennlig hilsen

David Larsen 

-Opprinnelig melding-
Fra: Daan Hoogland 
Sendt: mandag 4. oktober 2021 16:59
Til: users 
Emne: Re: Dynamic Roles and user roles in command.properties

David,
The '=15's mean user is allowed, as 15 = 8+4=2=1 (it is a decimal description 
of a bit-field) Have you created any roles along the way?

On Mon, Oct 4, 2021 at 4:51 PM David Larsen  wrote:

> Hi
>
> I have tried to migrate our Cloudstack (4.15) to use dynamic roles. 
> The migrate process went ok, but users can't log in afterwards...(?).
> When they log in, the only response they get is "discovering..."
> I had to go back to commands.properties.
>
> What are the default user roles  when using dynamic roles?
>
> Which roles are migrated from commands.properties when using 
> migrate-dynamicroles.py?
>
> I have never changed anything in the commands.properties file while 
> upgrading from version 4.2->4.15 through the years.
>
> When I look in the commands.properties file, I see in the description 
> 8=user I can't fint any line in this file with =8
>
> Parts of our commands.properties file:
>
> :/etc/cloudstack/management# cat commands.properties # Licensed to the 
> Apache Software Foundation (ASF) under one # or more contributor 
> license agreements.  See the NOTICE file # distributed with this work 
> for additional information # regarding copyright ownership.  The ASF 
> licenses this file # to you under the Apache License, Version 2.0 (the 
> # "License"); you may not use this file except in compliance # with 
> the License.  You may obtain a copy of the License at #
> #   
> https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.apache.org%2Flicenses%2FLICENSE-2.0data=04%7C01%7C%7C564664e8460a4372d64008d9874e2666%7C1dd023eed2894f208926463c9b991b5f%7C1%7C0%7C637689591983049045%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000sdata=khjTG%2BqBtsoDVhdVpvztZWOpUFjt1z7K39WSJUZLjqk%3Dreserved=0
> #
> # Unless required by applicable law or agreed to in writing, # 
> software distributed under the License is distributed on an # "AS IS"
> BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # KIND, eith

SV: Dynamic Roles and user roles in command.properties

2021-10-04 Thread David Larsen
Hi Daan.

Thanks for your quick reply. 
I see.., 15 is user allowed.  didn't read the description good enough 
I have never created any roles.  I tried the -D option with 
migrate-dynamicroles.py 

Med vennlig hilsen

David Larsen 

-Opprinnelig melding-
Fra: Daan Hoogland  
Sendt: mandag 4. oktober 2021 16:59
Til: users 
Emne: Re: Dynamic Roles and user roles in command.properties

David,
The '=15's mean user is allowed, as 15 = 8+4=2=1 (it is a decimal description 
of a bit-field) Have you created any roles along the way?

On Mon, Oct 4, 2021 at 4:51 PM David Larsen  wrote:

> Hi
>
> I have tried to migrate our Cloudstack (4.15) to use dynamic roles. 
> The migrate process went ok, but users can't log in afterwards...(?).
> When they log in, the only response they get is "discovering..."
> I had to go back to commands.properties.
>
> What are the default user roles  when using dynamic roles?
>
> Which roles are migrated from commands.properties when using 
> migrate-dynamicroles.py?
>
> I have never changed anything in the commands.properties file while 
> upgrading from version 4.2->4.15 through the years.
>
> When I look in the commands.properties file, I see in the description 
> 8=user I can't fint any line in this file with =8
>
> Parts of our commands.properties file:
>
> :/etc/cloudstack/management# cat commands.properties # Licensed to the 
> Apache Software Foundation (ASF) under one # or more contributor 
> license agreements.  See the NOTICE file # distributed with this work 
> for additional information # regarding copyright ownership.  The ASF 
> licenses this file # to you under the Apache License, Version 2.0 (the 
> # "License"); you may not use this file except in compliance # with 
> the License.  You may obtain a copy of the License at #
> #   
> https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.apache.org%2Flicenses%2FLICENSE-2.0data=04%7C01%7C%7C224ec44958d649a1fe9d08d987477ac6%7C1dd023eed2894f208926463c9b991b5f%7C1%7C1%7C637689563332802043%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000sdata=oPHF87TtYNZ5PWqNJdVjMdXVTVpPTNcGJUMlyWMasAo%3Dreserved=0
> #
> # Unless required by applicable law or agreed to in writing, # 
> software distributed under the License is distributed on an # "AS IS" 
> BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # KIND, either express 
> or implied.  See the License for the # specific language governing 
> permissions and limitations # under the License.
>
> ### bitmap of permissions at the end of each classname, 1 = ADMIN, 2 = 
> RESOURCE_DOMAIN_ADMIN, 4 = DOMAIN_ADMIN, 8 = USER ### Please 
> standardize naming conventions to camel-case (even for acronyms).
>
> ### CloudStack authentication commands
> login=15
> logout=15
>
> ### SAML SSO/SLO commands
> samlSso=15
> samlSlo=15
> getSPMetadata=15
> listIdps=15
> authorizeSamlSso=7
> listSamlAuthorization=7
> listAndSwitchSamlAccount=15
>
> ### Account commands
> createAccount=7
> deleteAccount=7
> updateAccount=7
> disableAccount=7
> enableAccount=7
> lockAccount=7
> listAccounts=15
> markDefaultZoneForAccount=1
>
>  User commands
> createUser=7
> deleteUser=7
> updateUser=15
> listUsers=15
> lockUser=7
> disableUser=7
> enableUser=7
> getUser=1
>
>  Domain commands
> createDomain=1
> updateDomain=1
> deleteDomain=1
> listDomains=7
> listDomainChildren=7
>
> Cloud Identifier commands
> getCloudIdentifier=15
>
>  Limit commands
> updateResourceLimit=7
> updateResourceCount=7
> listResourceLimits=15
>
>  VM commands
> deployVirtualMachine=15
> destroyVirtualMachine=15
> rebootVirtualMachine=15
> startVirtualMachine=15
> stopVirtualMachine=15
> resetPasswordForVirtualMachine=15
> resetSSHKeyForVirtualMachine=15
> updateVirtualMachine=15
> listVirtualMachines=15
> getVMPassword=15
> restoreVirtualMachine=15
> changeServiceForVirtualMachine=15
> scaleVirtualMachine=15
> assignVirtualMachine=7
> migrateVirtualMachine=1
> migrateVirtualMachineWithVolume=1
> recoverVirtualMachine=15
> expungeVirtualMachine=15
> getVirtualMachineUserData=15
>
>  snapshot commands
> createSnapshot=15
> listSnapshots=15
> deleteSnapshot=15
> createSnapshotPolicy=15
> updateSnapshotPolicy=15
> deleteSnapshotPolicies=15
> listSnapshotPolicies=15
> revertSnapshot=15
>
>  template commands
> createTemplate=15
> registerTemplate=15
> updateTemplate=15
> copyTemplate=15
> deleteTemplate=15
> listTemplates=15
> .
>
> Med vennlig hilsen
>
> David Larsen
> Senior systemkonsulent
>
>
>

--
Daan


Dynamic Roles and user roles in command.properties

2021-10-04 Thread David Larsen
Hi

I have tried to migrate our Cloudstack (4.15) to use dynamic roles. The migrate 
process went ok, but users can't log in afterwards...(?).  
When they log in, the only response they get is "discovering..."
I had to go back to commands.properties.

What are the default user roles  when using dynamic roles?

Which roles are migrated from commands.properties when using 
migrate-dynamicroles.py?

I have never changed anything in the commands.properties file while upgrading 
from version 4.2->4.15 through the years.

When I look in the commands.properties file, I see in the description 
8=user I can't fint any line in this file with =8 

Parts of our commands.properties file:

:/etc/cloudstack/management# cat commands.properties
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements.  See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership.  The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License.  You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied.  See the License for the
# specific language governing permissions and limitations
# under the License.

### bitmap of permissions at the end of each classname, 1 = ADMIN, 2 = 
RESOURCE_DOMAIN_ADMIN, 4 = DOMAIN_ADMIN, 8 = USER
### Please standardize naming conventions to camel-case (even for acronyms).

### CloudStack authentication commands
login=15
logout=15

### SAML SSO/SLO commands
samlSso=15
samlSlo=15
getSPMetadata=15
listIdps=15
authorizeSamlSso=7
listSamlAuthorization=7
listAndSwitchSamlAccount=15

### Account commands
createAccount=7
deleteAccount=7
updateAccount=7
disableAccount=7
enableAccount=7
lockAccount=7
listAccounts=15
markDefaultZoneForAccount=1

 User commands
createUser=7
deleteUser=7
updateUser=15
listUsers=15
lockUser=7
disableUser=7
enableUser=7
getUser=1

 Domain commands
createDomain=1
updateDomain=1
deleteDomain=1
listDomains=7
listDomainChildren=7

Cloud Identifier commands
getCloudIdentifier=15

 Limit commands
updateResourceLimit=7
updateResourceCount=7
listResourceLimits=15

 VM commands
deployVirtualMachine=15
destroyVirtualMachine=15
rebootVirtualMachine=15
startVirtualMachine=15
stopVirtualMachine=15
resetPasswordForVirtualMachine=15
resetSSHKeyForVirtualMachine=15
updateVirtualMachine=15
listVirtualMachines=15
getVMPassword=15
restoreVirtualMachine=15
changeServiceForVirtualMachine=15
scaleVirtualMachine=15
assignVirtualMachine=7
migrateVirtualMachine=1
migrateVirtualMachineWithVolume=1
recoverVirtualMachine=15
expungeVirtualMachine=15
getVirtualMachineUserData=15

 snapshot commands
createSnapshot=15
listSnapshots=15
deleteSnapshot=15
createSnapshotPolicy=15
updateSnapshotPolicy=15
deleteSnapshotPolicies=15
listSnapshotPolicies=15
revertSnapshot=15

 template commands
createTemplate=15
registerTemplate=15
updateTemplate=15
copyTemplate=15
deleteTemplate=15
listTemplates=15
.....

Med vennlig hilsen

David Larsen 
Senior systemkonsulent




SV: Best practice moving cloudstack 4.13.0.1 management server from centos 6.10 to Ubuntu 18.04 LTS

2021-05-26 Thread David Larsen
Hi

Sorry for late reply. 
I figured out the reason why I couldn't log in to the GUI on the new ubuntu 
server.
Seems like I need to copy the old commands.properties file from the old centos 
6.10 server to the new ubuntu server... (?)
I thought cloudstack 4.15 didn't use it anymore, especially since it is not 
included in the 4.13-4.15 installation?

Does anyone know which setting(s) in the commands.properties file I need to 
look into?



Med vennlig hilsen

David Larsen 
Senior systemkonsulent


ADCOM MOLDE, IT Data AS
Fabrikkvegen 13  | 6415 Molde 
david.lar...@adcom.no | www.adcom.no 

    

Følg oss på sosiale medier: 
 Tenk på miljøet før du skriver ut denne eposten


-Opprinnelig melding-
Fra: David Larsen  
Sendt: lørdag 27. mars 2021 00:39
Til: users@cloudstack.apache.org
Emne: RE: Best practice moving cloudstack 4.13.0.1 management server from 
centos 6.10 to Ubuntu 18.04 LTS

Ok, thanks.
I will try cli tool tomorrow.





Sendt fra min Galaxy



 Opprinnelig melding 
Fra: Alireza Eskandari 
Dato: 26.03.2021 22:52 (GMT+01:00)
Til: users@cloudstack.apache.org
Emne: Re: Best practice moving cloudstack 4.13.0.1 management server from 
centos 6.10 to Ubuntu 18.04 LTS

If you can use CS from CloudMonkey (CLI tool), I can say that it is working 
fine but you have some problems with GUI.


On Sat, Mar 27, 2021 at 2:16 AM David Larsen  wrote:

> Yes, have. Many times. Also different browsers.
>
> Management server and mysql server have same ip as in production, but 
> in isolated environment.
>
>
>
>
>
> Sendt fra min Galaxy
>
>
>
>  Opprinnelig melding 
> Fra: Alireza Eskandari 
> Dato: 26.03.2021 22:41 (GMT+01:00)
> Til: users@cloudstack.apache.org
> Emne: Re: Best practice moving cloudstack 4.13.0.1 management server 
> from centos 6.10 to Ubuntu 18.04 LTS
>
> If you are trying to login via the web gui, have you tried to clear 
> your browser cache?
> I recommend testing your browser private mode.
>
> On Sat, Mar 27, 2021 at 1:54 AM David Larsen 
> wrote:
>
> > Hi
> >
> > I have a working cloudstack 4.13.01 setup with two servers, one
> cloudstack
> > management running centos 6.10, and a mysql 5.1 running on centos 6.10.
> >
> >
> > I have build up a isolated environment with two Ubuntu 18.04 servers:
> > 1. Ubuntu 18.04 running mysql 5.7
> > 2. Ubuntu 18.04 running cloudstack management 4.13.01
> >
> > When i restore mysql data from the old mysql server and run 
> > cloudstack database setup without deploy as root and finish 
> > cloudstack setup, everething start up as normal and i get the 
> > cloudstack login in
> browser...
> > But i cannot log in... According to the cloudstack management log, 
> > admin
> is
> > successfully logged in... (?)
> >
> > What is missing?
> >
> > I thought i might be the difference i mysql version, so i installed 
> > a "new" centos 6.10 with mysql 5.1... But after a successful sql 
> > restore
> and
> > cloudstack install, i was surprised i got the same symptoms with login.
> >
> > Then i i though i might be something with ubuntu, so i installed the 
> > latest centos 7 as cloudstack management server... Samme result... I
> can't
> > log in. No error unless i try with wrong password... Then it says 
> > wrong
> > password...(?) i have tried with admin users and standard users. 
> > Same result.
> >
> > I can mysql server data and it looks the same as the one in production.
> > All usernames are the same..
> >
> > What am i missing?
> > Is there any api.Key or some config files i need to be aware... And 
> > copy to the new management server?
> >
> > -David
> >
> > Sendt fra min Galaxy
> >
> >
>


SV: Kubernetes service has not been configured properly to provision Kubernetes clusters

2021-04-22 Thread David Larsen
Thanks Pearl.

OK, I see. 
I tried to register a new CoreOS ova template from URL, but when I choose 
Hypervisor "VMware",  the "OS Type" disappear and replaced with "Keyboard Type" 
 so I cannot choose OS Type=CoreOS... 
Is this normal?
The template register result is "Ready=False" and Status: Did not find a guest 
OS with type otherLinux64Guest


David Larsen 

-Opprinnelig melding-
Fra: Pearl d'Silva  
Sendt: torsdag 22. april 2021 16:50
Til: users@cloudstack.apache.org
Emne: Re: Kubernetes service has not been configured properly to provision 
Kubernetes clusters

Hi David,

On CS 4.15, you will still have to register the CoreOS template to setup 
Kubernetes Clusters and register it with the same name as the global setting 
'cloud.kubernetes.cluster.template.name.'.
The ShapeBlue blog that you are probably referring to is something that will be 
made available in the next LTS release.

Thanks,
Pearl
____
From: David Larsen 
Sent: Thursday, April 22, 2021 7:47 PM
To: users@cloudstack.apache.org 
Subject: Kubernetes service has not been configured properly to provision 
Kubernetes clusters

Hi 

I have now upgraded from CS 4.13 to CS 4.15 and I have tried to configure 
Kubernetes service from the latest Cloudstack documentation page (CloudStack 
Kubernetes Service — Apache CloudStack 4.15.0.0 
documentation<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fdocs.cloudstack.apache.org%2Fen%2Flatest%2Fplugins%2Fcloudstack-kubernetes-service.htmldata=04%7C01%7C%7Cd4047d507be447676ca008d9059e31e5%7C1dd023eed2894f208926463c9b991b5f%7C1%7C0%7C637546999272338838%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000sdata=xkZKpR6hfKSHXnZzVokDStxGgiuNGrqRlhLJS0utV9k%3Dreserved=0>)
  with no success…

As I have read from this forum and shapeblue’s pages, the CoreOS template setup 
is not needed anymore. But do I need to configure anything else from the 
GUI/cmd regarding this?

My 4.15 system vm uploaded before upgrading to 4.15 is not marked as “public”… 
is this a problem? Should I delete it and create a new systemvm for 4.15?

I have added Kubernetes versions 1.16.0 and 1.16.3 and they are marked as 
“ready”.
The global parameter in Cloudstack for Kubernetes is enabled.

When I try to create Kubernetes cluster with a test user, I get this error:
Request Failed (530) Kubernetes service has not been configured properly to 
provision Kubernetes clusters



Med vennlig hilsen

David Larsen
Senior systemkonsulent



pearl.dsi...@shapeblue.com
https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.shapeblue.com%2Fdata=04%7C01%7C%7Cd4047d507be447676ca008d9059e31e5%7C1dd023eed2894f208926463c9b991b5f%7C1%7C0%7C637546999272338838%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000sdata=T%2FaE5I6Ds7PihIHfhbfTRIqPIQHFcRiSBy2a2QOfO%2BE%3Dreserved=0
3 London Bridge Street,  3rd floor, News Building, London  SE1 9SGUK @shapeblue
  
 



Kubernetes service has not been configured properly to provision Kubernetes clusters

2021-04-22 Thread David Larsen
Hi 

I have now upgraded from CS 4.13 to CS 4.15 and I have tried to configure 
Kubernetes service from the latest Cloudstack documentation page (CloudStack 
Kubernetes Service — Apache CloudStack 4.15.0.0 
documentation<http://docs.cloudstack.apache.org/en/latest/plugins/cloudstack-kubernetes-service.html>)
  with no success…

As I have read from this forum and shapeblue’s pages, the CoreOS template setup 
is not needed anymore. But do I need to configure anything else from the 
GUI/cmd regarding this?

My 4.15 system vm uploaded before upgrading to 4.15 is not marked as “public”… 
is this a problem? Should I delete it and create a new systemvm for 4.15?

I have added Kubernetes versions 1.16.0 and 1.16.3 and they are marked as 
“ready”.
The global parameter in Cloudstack for Kubernetes is enabled.

When I try to create Kubernetes cluster with a test user, I get this error:
Request Failed (530) Kubernetes service has not been configured properly to 
provision Kubernetes clusters



Med vennlig hilsen

David Larsen
Senior systemkonsulent




RE: Best practice moving cloudstack 4.13.0.1 management server from centos 6.10 to Ubuntu 18.04 LTS

2021-03-26 Thread David Larsen
Ok, thanks.
I will try cli tool tomorrow.





Sendt fra min Galaxy



 Opprinnelig melding 
Fra: Alireza Eskandari 
Dato: 26.03.2021 22:52 (GMT+01:00)
Til: users@cloudstack.apache.org
Emne: Re: Best practice moving cloudstack 4.13.0.1 management server from 
centos 6.10 to Ubuntu 18.04 LTS

If you can use CS from CloudMonkey (CLI tool), I can say that it is working
fine but you have some problems with GUI.


On Sat, Mar 27, 2021 at 2:16 AM David Larsen  wrote:

> Yes, have. Many times. Also different browsers.
>
> Management server and mysql server have same ip as in production, but in
> isolated environment.
>
>
>
>
>
> Sendt fra min Galaxy
>
>
>
>  Opprinnelig melding 
> Fra: Alireza Eskandari 
> Dato: 26.03.2021 22:41 (GMT+01:00)
> Til: users@cloudstack.apache.org
> Emne: Re: Best practice moving cloudstack 4.13.0.1 management server from
> centos 6.10 to Ubuntu 18.04 LTS
>
> If you are trying to login via the web gui, have you tried to clear your
> browser cache?
> I recommend testing your browser private mode.
>
> On Sat, Mar 27, 2021 at 1:54 AM David Larsen 
> wrote:
>
> > Hi
> >
> > I have a working cloudstack 4.13.01 setup with two servers, one
> cloudstack
> > management running centos 6.10, and a mysql 5.1 running on centos 6.10.
> >
> >
> > I have build up a isolated environment with two Ubuntu 18.04 servers:
> > 1. Ubuntu 18.04 running mysql 5.7
> > 2. Ubuntu 18.04 running cloudstack management 4.13.01
> >
> > When i restore mysql data from the old mysql server and run cloudstack
> > database setup without deploy as root and finish cloudstack setup,
> > everething start up as normal and i get the cloudstack login in
> browser...
> > But i cannot log in... According to the cloudstack management log, admin
> is
> > successfully logged in... (?)
> >
> > What is missing?
> >
> > I thought i might be the difference i mysql version, so i installed a
> > "new" centos 6.10 with mysql 5.1... But after a successful sql restore
> and
> > cloudstack install, i was surprised i got the same symptoms with login.
> >
> > Then i i though i might be something with ubuntu, so i installed the
> > latest centos 7 as cloudstack management server... Samme result... I
> can't
> > log in. No error unless i try with wrong password... Then it says wrong
> > password...(?) i have tried with admin users and standard users. Same
> > result.
> >
> > I can mysql server data and it looks the same as the one in production.
> > All usernames are the same..
> >
> > What am i missing?
> > Is there any api.Key or some config files i need to be aware... And copy
> > to the new management server?
> >
> > -David
> >
> > Sendt fra min Galaxy
> >
> >
>


RE: Best practice moving cloudstack 4.13.0.1 management server from centos 6.10 to Ubuntu 18.04 LTS

2021-03-26 Thread David Larsen
Yes, have. Many times. Also different browsers.

Management server and mysql server have same ip as in production, but in 
isolated environment.





Sendt fra min Galaxy



 Opprinnelig melding 
Fra: Alireza Eskandari 
Dato: 26.03.2021 22:41 (GMT+01:00)
Til: users@cloudstack.apache.org
Emne: Re: Best practice moving cloudstack 4.13.0.1 management server from 
centos 6.10 to Ubuntu 18.04 LTS

If you are trying to login via the web gui, have you tried to clear your
browser cache?
I recommend testing your browser private mode.

On Sat, Mar 27, 2021 at 1:54 AM David Larsen  wrote:

> Hi
>
> I have a working cloudstack 4.13.01 setup with two servers, one cloudstack
> management running centos 6.10, and a mysql 5.1 running on centos 6.10.
>
>
> I have build up a isolated environment with two Ubuntu 18.04 servers:
> 1. Ubuntu 18.04 running mysql 5.7
> 2. Ubuntu 18.04 running cloudstack management 4.13.01
>
> When i restore mysql data from the old mysql server and run cloudstack
> database setup without deploy as root and finish cloudstack setup,
> everething start up as normal and i get the cloudstack login in browser...
> But i cannot log in... According to the cloudstack management log, admin is
> successfully logged in... (?)
>
> What is missing?
>
> I thought i might be the difference i mysql version, so i installed a
> "new" centos 6.10 with mysql 5.1... But after a successful sql restore and
> cloudstack install, i was surprised i got the same symptoms with login.
>
> Then i i though i might be something with ubuntu, so i installed the
> latest centos 7 as cloudstack management server... Samme result... I can't
> log in. No error unless i try with wrong password... Then it says wrong
> password...(?) i have tried with admin users and standard users. Same
> result.
>
> I can mysql server data and it looks the same as the one in production.
> All usernames are the same..
>
> What am i missing?
> Is there any api.Key or some config files i need to be aware... And copy
> to the new management server?
>
> -David
>
> Sendt fra min Galaxy
>
>


Best practice moving cloudstack 4.13.0.1 management server from centos 6.10 to Ubuntu 18.04 LTS

2021-03-26 Thread David Larsen
Hi

I have a working cloudstack 4.13.01 setup with two servers, one cloudstack 
management running centos 6.10, and a mysql 5.1 running on centos 6.10.


I have build up a isolated environment with two Ubuntu 18.04 servers:
1. Ubuntu 18.04 running mysql 5.7
2. Ubuntu 18.04 running cloudstack management 4.13.01

When i restore mysql data from the old mysql server and run cloudstack database 
setup without deploy as root and finish cloudstack setup, everething start up 
as normal and i get the cloudstack login in browser... But i cannot log in... 
According to the cloudstack management log, admin is successfully logged in... 
(?)

What is missing?

I thought i might be the difference i mysql version, so i installed a "new" 
centos 6.10 with mysql 5.1... But after a successful sql restore and cloudstack 
install, i was surprised i got the same symptoms with login.

Then i i though i might be something with ubuntu, so i installed the latest 
centos 7 as cloudstack management server... Samme result... I can't log in. No 
error unless i try with wrong password... Then it says wrong password...(?) i 
have tried with admin users and standard users. Same result.

I can mysql server data and it looks the same as the one in production. All 
usernames are the same..

What am i missing?
Is there any api.Key or some config files i need to be aware... And copy to the 
new management server?

-David

Sendt fra min Galaxy