wesupport

25% off on first invoice for all services*

SPRING SALE

Use coupon

*Offer valid for new customers only

25% off on first invoice for all services*

SPRING SALE

Use coupon

*Offer valid for new customers only

Need help?

Our experts have had an average response time of 11.43 minutes in March 2024 to fix urgent issues.

We will keep your servers stable, secure, and fast at all times for one fixed price.

Plesk git authentication failed – How to resolve

by | May 31, 2021

Wondering how to resolve ‘Plesk git authentication failed’ error? We can help you.

This error can trigger in many different scenarios. It can happen mainly when trying to access the local git repository.

As part of our Server Management Services, we assist our customers with several Plesk queries.

Today, let us discuss how to resolve this error.

 

What are the causes for ‘Plesk git authentication failed’ error?

Today, Let us discuss the two different causes for this error and its solutions.

  • Firstly, the Git extension for Plesk currently does not add additional users to the Git protected directory.
  • Secondly, CageFS permitted ones does not have RPM-package git.

 

How can we resolve ‘Plesk git authentication failed’ error?

Today, let us see the symptoms of the error and how our Support Techs resolved it.

1.The Git extension for Plesk currently does not add additional users to the Git protected directory.

 

Symptoms

Below mentioned are some of the symptoms for the error.

  • On a Plesk for Linux server, configure a local Git repository on the subscription.
  • It is possible to work with the repository using the system user of the subscription:
# git clone http://sysuser@example.com/plesk-git/example.git
Cloning into ‘example’…
Password for ‘http://sysuser@example.com’:
remote: Counting objects: 2, done.
remote: Total 2 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (2/2), done.
  • Attempts to use Git repository as an additional FTP user created in Domains > example.com > FTP Access fail, even though the correct password is used:
# git clone http://gituser@example.com/plesk-git/example.git
Cloning into ‘example’…
Password for ‘http://gituser@example.com’:
  • The following error can occur in the domain’s log file /var/www/vhosts/example.com/logs/error_log when we usean additional user for accessing Git repository:
[auth_basic:error] [pid 2972:tid 140463692547840] [client 203.0.113.2:60065] AH01618: user gituser not found: /plesk-git/example.com/info/refs

 

Resolution

In order to resolve this, our Support techs added additional FTP users to the Git protected directory manually:

  1. Connect to the server using SSH.
  2. Use the following commands to manage Git users:
  • Firstly, add a new user:
# PSA_PASSWORD=example_password plesk sbin pdmng –add-user –vhost-name=example.com –directory=git@plesk-git –user-name=exampleuser
  • Secondly, modify already existing user:
# PSA_PASSWORD=new_password plesk sbin pdmng –update-user –vhost-name=example.com –directory=git@plesk-git –user-name=exampleuser
  • Next, remove a user:
# plesk sbin pdmng –remove-user –vhost-name=example.com –directory=git@plesk-git –user-name=exampleuser
  • Finally, list existing users:
# cat /var/www/vhosts/system/example.com/pd/d..git@plesk-git

 

2.CageFS permitted ones does not have RPM-package git.

 

Symptoms

Some of the possible symptoms detected by our Support Techs are mentioned below:

  • Plesk is installed on CloudLinux server and then install and enable CageFS feature.
  • Unable to access the local git repository. Attempt to execute git clone command fails:
git clone https://johndoe@example.com/plesk-git/my_app
Cloning into ‘repo’…
Password for ‘https://johndoe@example.com’:
fatal: repository ‘https://johndoe@example.com:7080/plesk-git/repo/’ not found
  • The following error is seen in web server log of the domain:
# tail -fn0 /var/www/vhosts/example.com/logs/error_log
[Tue Sep 19 00:32:36.985861 2017] [auth_basic:error] [pid 4217:tid 140077837539072] [client 203.0.113.2:36100] AH01617: user john.doe: authentication failure for “/plesk-git/example.git”: Password Mismatch

 

Resolution

  • Firstly, connect to the server using SSH.
  • Add git rpm package to CageFS and apply changes with below commands:
# cagefsctl –addrpm git
# cagefsctl –force-update
  • Make sure that the LoadModule directives exists and is no comment in /etc/httpd/conf.modules.d/01-cgi.conf file. It should look as below:
# cat /etc/httpd/conf.modules.d/01-cgi.conf | grep -v ^#
<IfModule mpm_worker_module>
LoadModule cgid_module modules/mod_cgid.so
</IfModule>
<IfModule mpm_event_module>
LoadModule cgid_module modules/mod_cgid.so
</IfModule>
<IfModule mpm_prefork_module>
LoadModule cgi_module modules/mod_cgi.so
</IfModule>
  • Finally, restart httpd service to apply changes:
# systemctl restart httpd.service

[Need help to fix Plesk error? We are available 24*7]

Conclusion

In short, this error can happen mainly when trying to access the local git repository. Today, we have discussed about the causes symptoms and how we can resolve the error.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

var google_conversion_label = "owonCMyG5nEQ0aD71QM";

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Categories

Tags