SSL Problem (migration from cpanel)

I have successfully migrated my cpanel backup to virtualmin. then (as a root) when I want to enable ssl for this account by ticking "Apache SSL website enabled?". And this shows up

=======================================

Changing IP address of virtual website .. .. done

Creating SSL certificate and private key .. .. SSL website failed! : Failed to open /home/xxxxx/ssl.cert.webmintmp.31822 : Permission denied at ../web-lib-funcs.pl line 1493, line 1.

Updating Webmin user .. .. done

Updating Webmin user .. .. done

Saving server details .. .. done

Applying web server configuration .. .. done

Re-loading Webmin .. .. done

====================================

I also try as an admin of the "virtual server", this menu "Apache SSL website enabled?" even cant be ticked. So both cases failed (as a root and as admin). Please fix this as it can "turn off" any new user from cPanel (mostly will just ditched this panel without asking for help first).

Status: 
Active

Comments

Howdy -- what is the username in question that should own that directory?

And what is the output of this command:

ls -la /home/xxxxx/

see updated post for screenshot

all the folder and files structure exactly like cpanel. I even thought I'm seeing cpanel folder.

the domain directory structure is not like this: /home/xxxx/domains/mydomain.com

but like this: /home/xxxx/mydomain.com

I also get this error, enabling ssl for other domain: SSL website failed! : Failed to open /home/xxx/domains/mydomain.com/ssl.cert.webmintmp.22756 : No such file or directory at ../web-lib-funcs.pl line 1493, line 1.

I have found the causes. This problem doesnt exist if i create virtual server manually. The problem exist when using cpanel migration feature.

1st it doesnt create "domains" for subserver folder. it explain the problem stated here #37101: SSL website failed. "SSL website failed! : Failed to open /home/website/domains/subdomain.website.com/ssl.cert.webmintmp.25734 : No such file or directory at /usr/libexec/webmin/web-lib-funcs.pl ." im sure he is also using cpanel importer. (error when enabling ssl in sub server)

2nd the owner of all the folder is wrong. (look at my screenshoot) why all the folder's owner is admin@mymaindomain.com ? so this explain this error "SSL website failed! : Failed to open /home/xxxxx/ssl.cert.webmintmp.31822 : Permission denied at ../web-lib-funcs.pl line 1493, line 1." (error when enabling ssl in top level server)

So is the domain for which you're getting this SSL error a top-level virtual server, or a sub-server?

It seems like the cause is that the SSL cert path being attempted is of the format that you'd expect for a new domain, not the custom home directory path that is used for cpanel migrated domains.