{"thread":{"id":"23922","subject":"git pull works remotely but not locally","startedAt":"2010-05-27T13:35:07Z","lastAt":"2010-05-28T08:24:39Z","messageCount":17,"participants":["Ivan Uemlianin","Ramkumar Ramachandra","Sverre Rabbelier","Jeff King","Johannes Sixt","Ilari Liusvaara"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"142423","messageId":"4BFE750B.5030007@llaisdy.com","threadId":"23922","inReplyTo":null,"subject":"git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T13:35:07Z","receivedAt":"2010-05-27T13:35:07Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Dear All\n\nI have just set up my first git repository, and I'm trying things out \nbefore using it for real.  To start with I'm using a centralised \nworkflow with the main repos on a server, and workers checking work out \nand in.  I'm using the smart http backend.  I can contact the repos \nremotely via http or locally using the filesystem.  However, git pull is \nnot working in the local case.  Please can someone offer help with (a) \nfile permissions, and (b) difference between git pull, and git fetch; \ngit merge (which works):\n\nThe basics seem to be working OK remotely: ie contacting the server over \nhttp:\n\n         git clone http://username@12.34.56.78/git/projectname.git\n\nWhat I mean is push and pull are working.\n\nWhen working on the server itself I'm using\n\n         git clone  /var/www/git/projectname.git\n\nMost things seem to work the same, but git pull does not work:\n\n         $ git pull\n         fatal: cannot exec 'git-pull': Permission denied\n\nfetch followed by merge seems to have the desired effect, e.g.:\n\n    $ git fetch\n    remote: Counting objects: 5, done.\n    remote: Compressing objects: 100% (2/2), done.\n    remote: Total 3 (delta 1), reused 0 (delta 0)\n    Unpacking objects: 100% (3/3), done.\n     From /var/www/git/projectname\n        6b40c1f..4ffb389  master     -> origin/master\n\n    $ git merge origin\n    Updating 6b40c1f..4ffb389\n    Fast-forward\n      notes.txt |    1 +\n      1 files changed, 1 insertions(+), 0 deletions(-)\n\n\nSo, my questions are:\n\n(a)  Why isn't git pull working in the second case?  What permissions am \nI missing?\n(b)  Does git fetch; git merge origin do the same thing as git pull?\n\nWith thanks and best wishes\n\nIvan\n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142432","messageId":"AANLkTikmrBQ1aUQeAZKB8pdgwXjureozZOzEHq8CF4kb@mail.gmail.com","threadId":"23922","inReplyTo":"4BFE750B.5030007@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Ramkumar Ramachandra","fromEmail":"artagnon@gmail.com","sentAt":"2010-05-27T14:20:59Z","receivedAt":"2010-05-27T14:20:59Z","isPatch":false,"sender":{"key":"r@artagnon.com","avatar":"https://avatars.githubusercontent.com/u/37226?v=4"},"body":"Hi,\n\n>        $ git pull\n>        fatal: cannot exec 'git-pull': Permission denied\n\ngit-pull is simply a shell script (see git-pull.sh in git.git) which\nexecutes `git fetch` and `git merge-base` among other things. Maybe\nyour git-pull file doesn't have execute permissions?\n\n-- Ram\n"},{"id":"142434","messageId":"4BFE83A7.4020604@llaisdy.com","threadId":"23922","inReplyTo":"AANLkTikmrBQ1aUQeAZKB8pdgwXjureozZOzEHq8CF4kb@mail.gmail.com","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T14:37:27Z","receivedAt":"2010-05-27T14:37:27Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Dear Ram\n\nThank you for your comment.\n\ngit-pull is 755, and I can run /path/to/git-pull (I get an error and it \ncrashes, but I have the permission).\n\nIvan\n\nOn 27/05/2010 15:20, Ramkumar Ramachandra wrote:\n> Hi,\n>\n>    \n>>         $ git pull\n>>         fatal: cannot exec 'git-pull': Permission denied\n>>      \n> git-pull is simply a shell script (see git-pull.sh in git.git) which\n> executes `git fetch` and `git merge-base` among other things. Maybe\n> your git-pull file doesn't have execute permissions?\n>\n> -- Ram\n>    \n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142436","messageId":"AANLkTinn_D2nrZDoczHqvAFKdCxxubK0N0jHr-nE94JP@mail.gmail.com","threadId":"23922","inReplyTo":"4BFE83A7.4020604@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Sverre Rabbelier","fromEmail":"srabbelier@gmail.com","sentAt":"2010-05-27T14:47:50Z","receivedAt":"2010-05-27T14:47:50Z","isPatch":false,"sender":{"key":"srabbelier@gmail.com","avatar":"https://avatars.githubusercontent.com/u/3098?v=4"},"body":"Heya,\n\nOn Thu, May 27, 2010 at 16:37, Ivan Uemlianin <ivan@llaisdy.com> wrote:\n> git-pull is 755, and I can run /path/to/git-pull (I get an error and it\n> crashes, but I have the permission).\n\nThat's not supposed to happen, what does it say? Also, is it possible\nyou have an old git install lying around? It might be that it's partly\nusing the old, and partly using the new install.\n\n-- \nCheers,\n\nSverre Rabbelier\n"},{"id":"142437","messageId":"AANLkTikY6-Q1UphyfpsBo6_Hu98ZbVyeGmB7ZmI8FbTC@mail.gmail.com","threadId":"23922","inReplyTo":"4BFE83A7.4020604@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Ramkumar Ramachandra","fromEmail":"artagnon@gmail.com","sentAt":"2010-05-27T14:50:50Z","receivedAt":"2010-05-27T14:50:50Z","isPatch":false,"sender":{"key":"r@artagnon.com","avatar":"https://avatars.githubusercontent.com/u/37226?v=4"},"body":"Hi,\n\nOn Thu, May 27, 2010 at 4:37 PM, Ivan Uemlianin <ivan@llaisdy.com> wrote:\n> git-pull is 755, and I can run /path/to/git-pull (I get an error and it\n> crashes, but I have the permission).\n\nYour error comes from run-command.c:290 - Maybe it tries to execute\ngit-pull and (wrongly) reports that it wasn't able to execute it? What\nerror (and return status) do you get when you execute the script\nyourself?\nIt looks like there's something wrong with your installation of Git.\nPerhaps you'd like to re-install?\n\n-- Ram\n"},{"id":"142438","messageId":"4BFE8A99.5060906@llaisdy.com","threadId":"23922","inReplyTo":"AANLkTinn_D2nrZDoczHqvAFKdCxxubK0N0jHr-nE94JP@mail.gmail.com","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T15:07:05Z","receivedAt":"2010-05-27T15:07:05Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Dear All\n\nThanks for your comments.\n\nOn Thu, May 27, 2010 at 4:37 PM, Ivan Uemlianin<ivan@llaisdy.com>  wrote:\n\n> >  git-pull is 755, and I can run /path/to/git-pull (I get an error and it\n> >  crashes, but I have the permission).\n>    \n\nOn 27/05/2010 15:47, Sverre Rabbelier wrote:\n> ...\n> That's not supposed to happen, what does it say? Also, is it possible\n> you have an old git install lying around? It might be that it's partly\n> using the old, and partly using the new install.\n>    \n\nOn 27/05/2010 15:50, Ramkumar Ramachandra wrote:\n> ...\n> Your error comes from run-command.c:290 - Maybe it tries to execute\n> git-pull and (wrongly) reports that it wasn't able to execute it? What\n> error (and return status) do you get when you execute the script\n> yourself?\n> It looks like there's something wrong with your installation of Git.\n> Perhaps you'd like to re-install\n>    \nThe error is like this:\n\n     $ /opt/libexec/git-core/git-pull\n     /opt/libexec/git-core/git-pull: line 11: git-sh-setup: No such file \nor directory\n\nI'm calling git-pull from my clone of the repos, so I don't have \ngit-sh-setup in my current directory.  That all seems fine: I imagine \ngit-pull is not intended to be called directly.\n\nThe git is a recent install from source, on a Centos machine.  There was \nno git previous.\n\nAs for reinstalling: unless something else is broken, I'm happy with \n\"git fetch; git merge origin\".  However, I should like to understand why \ngit pull is not working.\n\nBest wishes\n\nIvan\n\n\n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142440","messageId":"20100527151514.GB18590@coredump.intra.peff.net","threadId":"23922","inReplyTo":"4BFE8A99.5060906@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2010-05-27T15:15:14Z","receivedAt":"2010-05-27T15:15:14Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, May 27, 2010 at 04:07:05PM +0100, Ivan Uemlianin wrote:\n\n> >It looks like there's something wrong with your installation of Git.\n> >Perhaps you'd like to re-install\n> The error is like this:\n> \n>     $ /opt/libexec/git-core/git-pull\n>     /opt/libexec/git-core/git-pull: line 11: git-sh-setup: No such\n> file or directory\n> \n> I'm calling git-pull from my clone of the repos, so I don't have\n> git-sh-setup in my current directory.  That all seems fine: I imagine\n> git-pull is not intended to be called directly.\n\nIt's not. It expects the git wrapper to have set up the PATH to have\n/opt/libexec/git-core in it, which would then find git-sh-setup.\n\nWhat happens if you run \"git pull\"? If you get an error, can you try to\nrun \"GIT_TRACE=1 git pull\"? Git should then print out exactly what it is\ntrying to exec that is failing.\n\n-Peff\n"},{"id":"142441","messageId":"AANLkTimDOOjbCRJMOlW8sTEtiHdI4AqjdOcdFug7MD94@mail.gmail.com","threadId":"23922","inReplyTo":"4BFE8A99.5060906@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Ramkumar Ramachandra","fromEmail":"artagnon@gmail.com","sentAt":"2010-05-27T15:15:54Z","receivedAt":"2010-05-27T15:15:54Z","isPatch":false,"sender":{"key":"r@artagnon.com","avatar":"https://avatars.githubusercontent.com/u/37226?v=4"},"body":"Hi,\n\n>    /opt/libexec/git-core/git-pull: line 11: git-sh-setup: No such file or\n> directory\n\nYou seem to be missing git-sh-setup (called `git-sh-setup.sh` in\ngit.git), another shell script that's called by every other shell\nscript in Git.\n\n> As for reinstalling: unless something else is broken, I'm happy with \"git\n> fetch; git merge origin\".  However, I should like to understand why git pull\n> is not working.\n\nA lot of other things won't work. `git rebase -i` for example is\nanother shell script `git-rebase--interactive.sh`.\n\n-- Ram\n"},{"id":"142443","messageId":"4BFE8DF8.8050301@llaisdy.com","threadId":"23922","inReplyTo":"20100527151514.GB18590@coredump.intra.peff.net","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T15:21:28Z","receivedAt":"2010-05-27T15:21:28Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Dear Peff\n\nThanks for your comment.\n> What happens if you run \"git pull\"? If you get an error, can you try to\n> run \"GIT_TRACE=1 git pull\"? Git should then print out exactly what it is\n> trying to exec that is failing.\n\nNot very exciting:\n\n$ GIT_TRACE=1 git pull\ntrace: exec: 'git-pull'\ntrace: run_command: 'git-pull'\nfatal: cannot exec 'git-pull': Permission denied\n\nBest wishes\n\nIvan\n\n\nOn 27/05/2010 16:15, Jeff King wrote:\n> On Thu, May 27, 2010 at 04:07:05PM +0100, Ivan Uemlianin wrote:\n>\n>    \n>>> It looks like there's something wrong with your installation of Git.\n>>> Perhaps you'd like to re-install\n>>>        \n>> The error is like this:\n>>\n>>      $ /opt/libexec/git-core/git-pull\n>>      /opt/libexec/git-core/git-pull: line 11: git-sh-setup: No such\n>> file or directory\n>>\n>> I'm calling git-pull from my clone of the repos, so I don't have\n>> git-sh-setup in my current directory.  That all seems fine: I imagine\n>> git-pull is not intended to be called directly.\n>>      \n> It's not. It expects the git wrapper to have set up the PATH to have\n> /opt/libexec/git-core in it, which would then find git-sh-setup.\n>\n> What happens if you run \"git pull\"? If you get an error, can you try to\n> run \"GIT_TRACE=1 git pull\"? Git should then print out exactly what it is\n> trying to exec that is failing.\n>\n> -Peff\n>    \n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142444","messageId":"4BFE8FB4.60002@viscovery.net","threadId":"23922","inReplyTo":"4BFE8DF8.8050301@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Johannes Sixt","fromEmail":"j.sixt@viscovery.net","sentAt":"2010-05-27T15:28:52Z","receivedAt":"2010-05-27T15:28:52Z","isPatch":false,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"Please Reply-To-All, do not cull Cc list.\n\nAm 5/27/2010 17:21, schrieb Ivan Uemlianin:\n> $ GIT_TRACE=1 git pull\n> trace: exec: 'git-pull'\n> trace: run_command: 'git-pull'\n> fatal: cannot exec 'git-pull': Permission denied\n\nYou get 'Permission denied' also if you cannot execute the shell that the\nfirst line of the script references. But that would be really odd...\n\n-- Hannes\n"},{"id":"142448","messageId":"4BFE9172.9080209@llaisdy.com","threadId":"23922","inReplyTo":"AANLkTimDOOjbCRJMOlW8sTEtiHdI4AqjdOcdFug7MD94@mail.gmail.com","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T15:36:18Z","receivedAt":"2010-05-27T15:36:18Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"On 27/05/2010 16:15, Ramkumar Ramachandra wrote:\n> Hi,\n>\n>    \n>>     /opt/libexec/git-core/git-pull: line 11: git-sh-setup: No such file or\n>> directory\n>>      \n> You seem to be missing git-sh-setup (called `git-sh-setup.sh` in\n> git.git), another shell script that's called by every other shell\n> script in Git.\n>    \n... but git-sh-setup is in /opt/libexec/git-core/ ...\n>> As for reinstalling: unless something else is broken, I'm happy with \"git\n>> fetch; git merge origin\".  However, I should like to understand why git pull\n>> is not working.\n>>      \n> A lot of other things won't work. `git rebase -i` for example is\n> another shell script `git-rebase--interactive.sh`.\n>    \nYou're right!\n\nIs there something I need to set in my global .gitconfig?\n\nIf it's a botched install I need to know why, or it will just be botched \nthe same way when I reinstall.  I only remember two things about the \ninstall, ...\n\n- I did configure with prefix=/opt\n- odd thing: nothing was installed into /opt: it all went into /root (I \nmight have been root for the whole process, which I know is bad).  I \njust cp'd everything over to /opt, and everything worked OK (until now).\n\nAny ideas?  I'm happy to reinstall once I know what went wrong.  The git \nI installed on my mac is really working fine.\n\nBest wishes\n\nIvan\n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142449","messageId":"4BFE91A4.5000205@llaisdy.com","threadId":"23922","inReplyTo":"4BFE8FB4.60002@viscovery.net","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T15:37:08Z","receivedAt":"2010-05-27T15:37:08Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Yes, that would be odd.  I can run /bin/sh :)\n\nOn 27/05/2010 16:28, Johannes Sixt wrote:\n> Please Reply-To-All, do not cull Cc list.\n>\n> Am 5/27/2010 17:21, schrieb Ivan Uemlianin:\n>    \n>> $ GIT_TRACE=1 git pull\n>> trace: exec: 'git-pull'\n>> trace: run_command: 'git-pull'\n>> fatal: cannot exec 'git-pull': Permission denied\n>>      \n> You get 'Permission denied' also if you cannot execute the shell that the\n> first line of the script references. But that would be really odd...\n>\n> -- Hannes\n>    \n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142450","messageId":"20100527153812.GA23484@coredump.intra.peff.net","threadId":"23922","inReplyTo":"4BFE8DF8.8050301@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2010-05-27T15:38:12Z","receivedAt":"2010-05-27T15:38:12Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, May 27, 2010 at 04:21:28PM +0100, Ivan Uemlianin wrote:\n\n> Thanks for your comment.\n> >What happens if you run \"git pull\"? If you get an error, can you try to\n> >run \"GIT_TRACE=1 git pull\"? Git should then print out exactly what it is\n> >trying to exec that is failing.\n> \n> Not very exciting:\n> \n> $ GIT_TRACE=1 git pull\n> trace: exec: 'git-pull'\n> trace: run_command: 'git-pull'\n> fatal: cannot exec 'git-pull': Permission denied\n\nThen the next thing to try is probably (assuming you are running Linux):\n\n  strace -f -e execve git pull\n\nThough I suspect we may just see:\n\n  execve(\"/opt/libexec/git-core/git-core/git-pull\", ...) = -1 EACCES (Permission denied)\n\nwhich doesn't help much. I just want to be sure that is the source of\nthe problem.\n\n-Peff\n"},{"id":"142454","messageId":"4BFE9C1E.7050308@llaisdy.com","threadId":"23922","inReplyTo":"20100527153812.GA23484@coredump.intra.peff.net","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-27T16:21:50Z","receivedAt":"2010-05-27T16:21:50Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"On 27/05/2010 16:38, Jeff King wrote:\n> Then the next thing to try is probably (assuming you are running Linux):\n>    \nWell, kind of: it's CentOS, which I'm finding quite recalcitrant (e.g. I \nhad to install strace).\n>    strace -f -e execve git pull\n>\n> Though I suspect we may just see:\n>\n>    execve(\"/opt/libexec/git-core/git-core/git-pull\", ...) = -1 EACCES (Permission denied)\n>\n> which doesn't help much. I just want to be sure that is the source of\n> the problem.\n>    \nNo, the output is interesting.  The permissions denied is from the \nerroneous /root install (see separate email):\n\n     [pid  3485] execve(\"/root/libexec/git-core/git-pull\", [\"git-pull\"], \n[/* 18 vars */]) = -1 EACCES (Permission denied)\n\nIt looks in /opt/bin, but not /opt/libexec.\n\nIt could be a botched git install or it could be a botched PATH --- I \nhave had to fiddle about with it a bit.  For example, /opt/libexec is \nnot on my PATH  ...  In fact my PATH *is* botched:\n\n     $ $PATH\n     bash: /opt/bin:<snip/>:/usr/bin:/root/bin: No such file or directory\n\nThose last two items don't look good at all.  And:\n\n     $ PATH=/opt/libexec/git-core/:$PATH\n     $ git pull\n     remote: Counting objects: 8, done.\n     ...\n      1 files changed, 2 insertions(+), 1 deletions(-)\n\nWorking!\n\nSo:\n- git itself is probably OK\n- I have a botched PATH, which I should fix asap\n\nDoes git expect certain paths to be on a user's PATH?  If so perhaps \nthat is all that is wrong.\n\nBest wishes\n\nIvan\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"},{"id":"142457","messageId":"20100527165700.GA9909@LK-Perkele-V2.elisa-laajakaista.fi","threadId":"23922","inReplyTo":"4BFE9C1E.7050308@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Ilari Liusvaara","fromEmail":"ilari.liusvaara@elisanet.fi","sentAt":"2010-05-27T16:57:00Z","receivedAt":"2010-05-27T16:57:00Z","isPatch":false,"sender":{"key":"ilari.liusvaara@elisanet.fi","avatar":null},"body":"On Thu, May 27, 2010 at 05:21:50PM +0100, Ivan Uemlianin wrote:\n> On 27/05/2010 16:38, Jeff King wrote:\n> >Then the next thing to try is probably (assuming you are running Linux):\n> Well, kind of: it's CentOS, which I'm finding quite recalcitrant\n> (e.g. I had to install strace).\n> >   strace -f -e execve git pull\n> >\n> >Though I suspect we may just see:\n> >\n> >   execve(\"/opt/libexec/git-core/git-core/git-pull\", ...) = -1 EACCES (Permission denied)\n> >\n> >which doesn't help much. I just want to be sure that is the source of\n> >the problem.\n> No, the output is interesting.  The permissions denied is from the\n> erroneous /root install (see separate email):\n> \n>     [pid  3485] execve(\"/root/libexec/git-core/git-pull\",\n> [\"git-pull\"], [/* 18 vars */]) = -1 EACCES (Permission denied)\n> \n> It looks in /opt/bin, but not /opt/libexec.\n \nThat looks like you are either running wrong git binary (one in /root/bin?)\nor the git installation is busted.\n\nNo, the git libexec directory SHOULD NOT be in PATH (git will add it there\nwhen needed).\n\n-Ilari\n"},{"id":"142465","messageId":"201005272153.54239.j6t@kdbg.org","threadId":"23922","inReplyTo":"4BFE9172.9080209@llaisdy.com","subject":"Re: git pull works remotely but not locally","fromName":"Johannes Sixt","fromEmail":"j6t@kdbg.org","sentAt":"2010-05-27T19:53:54Z","receivedAt":"2010-05-27T19:53:54Z","isPatch":false,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"On Donnerstag, 27. Mai 2010, Ivan Uemlianin wrote:\n> - I did configure with prefix=/opt\n> - odd thing: nothing was installed into /opt: it all went into /root (I\n> might have been root for the whole process, which I know is bad).  I\n> just cp'd everything over to /opt, and everything worked OK (until now).\n\nMy guess is:\n\n- You built as root.\n- I don't know what went wrong with the command that involved prefix=/opt.\n- But when you finally build using 'make', it picked the default prefix, which \nis /root when you are root.\n- This hard-codes the libexec path to /root/libexec/git-core.\n- Even after you copy the stuff to /opt, git looks in /root/libexec/...\n- As a normal user you do not have access to /root, ergo, Permission denied.\n\nRebuild as normal user with\n\n   make prefix=/opt\n\nand install as root with\n\n   make prefix=/opt install\n\n(Yes, prefix must be given also for 'make install'.)\n\n-- Hannes\n"},{"id":"142487","messageId":"4BFF7DC7.6030806@llaisdy.com","threadId":"23922","inReplyTo":"201005272153.54239.j6t@kdbg.org","subject":"Re: git pull works remotely but not locally","fromName":"Ivan Uemlianin","fromEmail":"ivan@llaisdy.com","sentAt":"2010-05-28T08:24:39Z","receivedAt":"2010-05-28T08:24:39Z","isPatch":false,"sender":{"key":"ivan@llaisdy.com","avatar":null},"body":"Dear Hannes\n\nYes, you have pinpointed it.  I installed as root, but I thought I had \nfollowed the other instructions (using ./configure) and did\n\n    # make configure\n    # ./configure --prefix=/opt\n    # make\n    # make install\n\n\nIn any case, I have deleted everything and reinstalled properly.  Now \ngit pull is working as it should.\n\nThank you all for your patience and help.\n\nBest wishes\n\nIvan\n\n\nOn 27/05/2010 20:53, Johannes Sixt wrote:\n> On Donnerstag, 27. Mai 2010, Ivan Uemlianin wrote:\n>    \n>> - I did configure with prefix=/opt\n>> - odd thing: nothing was installed into /opt: it all went into /root (I\n>> might have been root for the whole process, which I know is bad).  I\n>> just cp'd everything over to /opt, and everything worked OK (until now).\n>>      \n> My guess is:\n>\n> - You built as root.\n> - I don't know what went wrong with the command that involved prefix=/opt.\n> - But when you finally build using 'make', it picked the default prefix, which\n> is /root when you are root.\n> - This hard-codes the libexec path to /root/libexec/git-core.\n> - Even after you copy the stuff to /opt, git looks in /root/libexec/...\n> - As a normal user you do not have access to /root, ergo, Permission denied.\n>\n> Rebuild as normal user with\n>\n>     make prefix=/opt\n>\n> and install as root with\n>\n>     make prefix=/opt install\n>\n> (Yes, prefix must be given also for 'make install'.)\n>\n> -- Hannes\n>    \n\n\n-- \n============================================================\nIvan A. Uemlianin\nSpeech Technology Research and Development\n\n                     ivan@llaisdy.com\n                      www.llaisdy.com\n                          llaisdy.wordpress.com\n                      www.linkedin.com/in/ivanuemlianin\n\n     \"Froh, froh! Wie seine Sonnen, seine Sonnen fliegen\"\n                      (Schiller, Beethoven)\n============================================================\n"}]}