You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@guacamole.apache.org by Remush <m....@gmail.com> on 2023/12/07 01:55:21 UTC

Guacamole Container Unable to start due to Postgresql.jar

I'm really not sure what is happening!
Hey there fellows!


So I'm setting up a Postgresql cluster with the guacamole accessing the VIP.

Now I have been able to set the postgresql db with the command:

cat schema/*.sql | psql -d -p 4321 -U guacadmin guacamole_db -f -

I'm also passing a certain password as  PGPASSWORD and the command is
successful!

The guacamole.properties:
postgresql_hostname: the vip of the guacamole
postgresql_database: guacamole_db
postgresql_username: guacadmin
postgresql_port: 4321
postgresql_password: the same password set at PGPASSWORD

Also I'm setting those VARs at ENV level when creating the container.

However when I set up the Guacamole, im Getting:


ln: failed to create symbolic link
'/home/guacamole/.guacamole/postgresql-42.6.0.jar': File exists

I understand that I might have configured something wrong But I don't
know where to look, It has no logs and it doesn't specify where is the
misconfiguration.

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Remush <m....@gmail.com>.
Last one I promise.
I tried the same thing with an LDAP guacamole extension and I copied it
into the container manually, and it worked!

Now I checked the script and it also has it just like the db extension.
So I'm a bit confused.
Is there a reason for this?

On Thu, 7 Dec 2023, 15:51 Nick Couchman, <vn...@apache.org> wrote:

> On Thu, Dec 7, 2023 at 8:41 AM Remush <m....@gmail.com> wrote:
>
>> Oh! Thank you so much!
>> Sorry for the silly questions
>>
>>
> No worries at all - this is what the mailing list is for :-). Better to
> ask the questions and learn than to not ask at all.
>
> -Nick
>
>>

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Nick Couchman <vn...@apache.org>.
On Thu, Dec 7, 2023 at 8:41 AM Remush <m....@gmail.com> wrote:

> Oh! Thank you so much!
> Sorry for the silly questions
>
>
No worries at all - this is what the mailing list is for :-). Better to ask
the questions and learn than to not ask at all.

-Nick

>

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Remush <m....@gmail.com>.
Oh! Thank you so much!
Sorry for the silly questions

On Thu, 7 Dec 2023, 14:41 Nick Couchman, <vn...@apache.org> wrote:

> On Thu, Dec 7, 2023 at 2:15 AM Remush <m....@gmail.com> wrote:
>
>> Oh okay, where does it get it ?
>>
>> Also after I removed the postgresql-42.6.0.jar I get a different error
>> message:
>>
>> ln: failed to create symbolic link '/home/guacamole/.guacamole/extensions/guacamole-auth-jdbc-postgresql-1.5.3.jar': File exists
>>
>>
> You should also remove this extension file from the directory/volume if
> you have manually added it. Again, the Docker startup script is meant to
> manage all of this for you. If you look in the startup script, in the
> PostgreSQL section:
>
>
> https://github.com/apache/guacamole-client/blob/212955c16c393c08f434f1def0ac12be36b09b2e/guacamole-docker/bin/start.sh#L296-L427
>
> You'll see these two lines toward the end:
>
>     # Add required .jar files to GUACAMOLE_LIB and GUACAMOLE_EXT
>     ln -s /opt/guacamole/postgresql/postgresql-*.jar "$GUACAMOLE_LIB"
>     ln -s /opt/guacamole/postgresql/guacamole-auth-*.jar "$GUACAMOLE_EXT"
>
> The Docker container already has the PostgreSQL JDBC driver and the
> Guacamole extension, and it links them when you configure Postgres. There
> is no need to place files manually in any directory, unless you're trying
> to enable an extension that isn't explicitly supported by the Docker
> script. However, Postgres is, so there's no need to do any manual file
> drops, etc.
>
> Perhaps do you also know why is there a .guacamole directory?
>> Because I set /etc/guacamole/ as the home directory
>>
>>
>>
> This is also determined by the startup script:
>
>
> https://github.com/apache/guacamole-client/blob/212955c16c393c08f434f1def0ac12be36b09b2e/guacamole-docker/bin/start.sh#L33-L36
>
> This allows the Tomcat service in the container to run as a non-root user
> without having to worry about the permissions of /etc/guacamole. There's no
> reason to try to change this, and the script will just override it, anyway.
>
> -Nick
>
>>

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Nick Couchman <vn...@apache.org>.
On Thu, Dec 7, 2023 at 2:15 AM Remush <m....@gmail.com> wrote:

> Oh okay, where does it get it ?
>
> Also after I removed the postgresql-42.6.0.jar I get a different error
> message:
>
> ln: failed to create symbolic link '/home/guacamole/.guacamole/extensions/guacamole-auth-jdbc-postgresql-1.5.3.jar': File exists
>
>
You should also remove this extension file from the directory/volume if you
have manually added it. Again, the Docker startup script is meant to manage
all of this for you. If you look in the startup script, in the PostgreSQL
section:

https://github.com/apache/guacamole-client/blob/212955c16c393c08f434f1def0ac12be36b09b2e/guacamole-docker/bin/start.sh#L296-L427

You'll see these two lines toward the end:

    # Add required .jar files to GUACAMOLE_LIB and GUACAMOLE_EXT
    ln -s /opt/guacamole/postgresql/postgresql-*.jar "$GUACAMOLE_LIB"
    ln -s /opt/guacamole/postgresql/guacamole-auth-*.jar "$GUACAMOLE_EXT"

The Docker container already has the PostgreSQL JDBC driver and the
Guacamole extension, and it links them when you configure Postgres. There
is no need to place files manually in any directory, unless you're trying
to enable an extension that isn't explicitly supported by the Docker
script. However, Postgres is, so there's no need to do any manual file
drops, etc.

Perhaps do you also know why is there a .guacamole directory?
> Because I set /etc/guacamole/ as the home directory
>
>
>
This is also determined by the startup script:

https://github.com/apache/guacamole-client/blob/212955c16c393c08f434f1def0ac12be36b09b2e/guacamole-docker/bin/start.sh#L33-L36

This allows the Tomcat service in the container to run as a non-root user
without having to worry about the permissions of /etc/guacamole. There's no
reason to try to change this, and the script will just override it, anyway.

-Nick

>

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Remush <m....@gmail.com>.
Oh okay, where does it get it ?

Also after I removed the postgresql-42.6.0.jar I get a different error
message:

ln: failed to create symbolic link
'/home/guacamole/.guacamole/extensions/guacamole-auth-jdbc-postgresql-1.5.3.jar':
File exists


Perhaps do you also know why is there a .guacamole directory?
Because I set /etc/guacamole/ as the home directory


On Thu, 7 Dec 2023, 5:26 Nick Couchman, <vn...@apache.org> wrote:

> On Wed, Dec 6, 2023 at 8:55 PM Remush <m....@gmail.com> wrote:
>
>> I'm really not sure what is happening!
>> Hey there fellows!
>>
>>
>> So I'm setting up a Postgresql cluster with the guacamole accessing the
>> VIP.
>>
>> Now I have been able to set the postgresql db with the command:
>>
>> cat schema/*.sql | psql -d -p 4321 -U guacadmin guacamole_db -f -
>>
>> I'm also passing a certain password as  PGPASSWORD and the command is successful!
>>
>> The guacamole.properties:
>> postgresql_hostname: the vip of the guacamole
>> postgresql_database: guacamole_db
>> postgresql_username: guacadmin
>> postgresql_port: 4321
>> postgresql_password: the same password set at PGPASSWORD
>>
>> Also I'm setting those VARs at ENV level when creating the container.
>>
>> However when I set up the Guacamole, im Getting:
>>
>>
>> ln: failed to create symbolic link '/home/guacamole/.guacamole/postgresql-42.6.0.jar': File exists
>>
>>
> An earlier e-mail you sent indicated that you were trying to place the
> postgresql JAR file in the directory manually. Make sure you are not doing
> this, and, if you're mapping the Guacamole home directory into Docker as a
> volume, that the existing directory does not contain a file of the same
> name. As I mentioned in a previous e-mail, the startup script manages that
> for you.
>
> -Nick
>
>>

Re: Guacamole Container Unable to start due to Postgresql.jar

Posted by Nick Couchman <vn...@apache.org>.
On Wed, Dec 6, 2023 at 8:55 PM Remush <m....@gmail.com> wrote:

> I'm really not sure what is happening!
> Hey there fellows!
>
>
> So I'm setting up a Postgresql cluster with the guacamole accessing the
> VIP.
>
> Now I have been able to set the postgresql db with the command:
>
> cat schema/*.sql | psql -d -p 4321 -U guacadmin guacamole_db -f -
>
> I'm also passing a certain password as  PGPASSWORD and the command is successful!
>
> The guacamole.properties:
> postgresql_hostname: the vip of the guacamole
> postgresql_database: guacamole_db
> postgresql_username: guacadmin
> postgresql_port: 4321
> postgresql_password: the same password set at PGPASSWORD
>
> Also I'm setting those VARs at ENV level when creating the container.
>
> However when I set up the Guacamole, im Getting:
>
>
> ln: failed to create symbolic link '/home/guacamole/.guacamole/postgresql-42.6.0.jar': File exists
>
>
An earlier e-mail you sent indicated that you were trying to place the
postgresql JAR file in the directory manually. Make sure you are not doing
this, and, if you're mapping the Guacamole home directory into Docker as a
volume, that the existing directory does not contain a file of the same
name. As I mentioned in a previous e-mail, the startup script manages that
for you.

-Nick

>