Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Everytime I execute git pull origin master on my laptop, I get an error. This does not happen on any of my other computers or linux servers. The only difference with my laptop is that I recently upgraded from ubuntu 11.10 to 12.04. Here are my terminal commands that generate the error:

www-data@john-laptop:~/huf$ git init
www-data@john-laptop:~/huf$ git remote add origin http://gitjohn@git.mywebsite.com/em-microsite
www-data@john-laptop:~/huf$ git pull origin master
Password for 'http://gitjohn@git.mywebsite.com': 
error: The requested URL returned error: 401 (curl_result = 22, http_code = 401, sha1 = 65a9a62cd53a7533ce48a463d5fa5622734bc38b)
error: Unable to find 65a9a62cd53a7533ce48a463d5fa5622734bc38b under http://gitjohn@git.mywebsite.com/em-microsite
Cannot obtain needed commit 65a9a62cd53a7533ce48a463d5fa5622734bc38b
while processing commit 642d437e3080f869503f663b2ea0013cb85ebe8a.
error: Fetch failed.

Does anyone know what's wrong and how I can fix? As mentioned, i don't encounter this error on any other linux computers and servers.

Additional notes: I typed in the same username and password on 8 different computers/passwords. The only time it fails is on my www-data@john-laptop computer. I suspect this might have something to do with my upgrade from ubuntu 11.10 to 12.04. Maybe i'll try re-installing git on that computer. Does anyone know of related issues? git works differently on different OS?

share|improve this question
    
Why the downvote and close? Isn't this the place to be asking about git server and/or linux based servers? –  John Dec 30 '12 at 23:02
    
It says your username and password are wrong. So check those. –  Michael Hampton Dec 30 '12 at 23:37
    
I did not downvote, or VTC; but I strongly suspect that they're on account of Server Fault being for Professional System Administrators only, who should know that 401 means "user error", not a problem with the software. –  Chris S Dec 30 '12 at 23:39
add comment

closed as off topic by SvW, Scott Pack, mdpc, Ward, Khaled Dec 31 '12 at 8:01

Questions on Server Fault are expected to relate to professional server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer

The requested URL returned error: 401 == Unauthorized

Check your username and password or other form of authorization.

share|improve this answer
    
I typed in the same username and password one 8 different computers/passwords. The only time it fails is on my john@laptop computer. I suspect this might have something to do with my upgrade from ubuntu 11.10 to 12.04. Maybe i'll try re-installing git on that computer. Do you know anything that might be related? –  John Dec 31 '12 at 1:20
    
@John Do you have access to logs? That way you can verify if the username/pw you see matches what the server sees. At least with that you can see if its a server problem or client problem –  TheLQ Dec 31 '12 at 3:20
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.