GithubHelp home page GithubHelp logo

Comments (12)

mpickering avatar mpickering commented on May 7, 2024

I can't reproduce this.

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

@mpickering Can you cat $(which serve) in your nix-shell?

from core-kythe.

mpickering avatar mpickering commented on May 7, 2024
#! /nix/store/zx8gzvhfrs1yaz7s1hnk93flj0ff7qp4-bash-4.4-p12/bin/bash

COMMAND=$1
shift
exec /nix/store/fjkcg8iqyma8cbg88q17c4l82nwkzyjv-kythe-0.0.26/tools/http_server --serving_table "/nix/store/xm92l97915kgb83w49sb1wx9vq751g0z-haskell-indexer-local-0.1/share/tbl" \
                               --listen=localhost:8080 \
                               --public_resources "/nix/store/fjkcg8iqyma8cbg88q17c4l82nwkzyjv-kythe-0.0.26/web/ui"

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

@mpickering The --serving_table "/nix/store/xm92l97915kgb83w49sb1wx9vq751g0z-haskell-indexer-local-0.1/share/tbl" is what makes the trouble. For me, it wants to open a LOCK file in that dir.

Not sure why it wouldn't try to do that for you. Should we compare versions of something?

from core-kythe.

mpickering avatar mpickering commented on May 7, 2024

Perhaps I shouldn't be running as root?

from core-kythe.

mpickering avatar mpickering commented on May 7, 2024

Do you know how people fix problems like this usually?

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

Perhaps I shouldn't be running as root?

@mpickering I don't think that matters; it's different for me (my user and the one that owns /nix is just niklas), but I think dir perms matter:

ls -lah /nix/store/xm92l97915kgb83w49sb1wx9vq751g0z-haskell-indexer-local-0.1/share/tbl
total 107M
dr-xr-xr-x 2 niklas niklas 4.0K Jan  1  1970 ./
dr-xr-xr-x 4 niklas niklas 4.0K Jan  1  1970 ../

Do you have the same? I do not have any chmod +w in there, do you?

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

Do you know how people fix problems like this usually?

@mpickering Well usually you are never supposed to try to write to /nix/store. It is supposed to be immutable; LevelDB isn't supposed to be allowed to write lock files there (which is why I find it weird that you can).

from core-kythe.

mpickering avatar mpickering commented on May 7, 2024
[root@nixos:~/core-kythe]# ls -lah /nix/store/xm92l97915kgb83w49sb1wx9vq751g0z-haskell-indexer-local-0.1/share/tbl/
total 17M
dr-xr-xr-x 2 root root 4.0K Aug 29 16:00 .
dr-xr-xr-x 4 root root 4.0K Jan  1  1970 ..
-rw-r--r-- 1 root root 240K Aug 17 16:42 000008.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000010.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000011.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000012.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000013.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000014.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000015.ldb
-rw-r--r-- 1 root root 2.1M Aug 17 16:42 000016.ldb
-rw-r--r-- 1 root root 2.0M Aug 17 16:42 000017.ldb
-rw-r--r-- 1 root root    0 Aug 29 16:00 000019.log
-rw-r--r-- 1 root root   16 Aug 29 16:00 CURRENT
-r--r--r-- 1 root root    0 Jan  1  1970 LOCK
-rw-r--r-- 1 root root  172 Aug 29 16:00 LOG
-rw-r--r-- 1 root root 2.3K Aug 17 16:42 LOG.old
-rw-r--r-- 1 root root 3.6K Aug 29 16:00 MANIFEST-000018

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

I should also have posted completely:

ls -lah /nix/store/xm92l97915kgb83w49sb1wx9vq751g0z-haskell-indexer-local-0.1/share/tbl
total 107M
dr-xr-xr-x 2 niklas niklas 4.0K Jan  1  1970 ./
dr-xr-xr-x 4 niklas niklas 4.0K Jan  1  1970 ../
-r--r--r-- 1 niklas niklas  63M Jan  1  1970 000003.log
-r--r--r-- 1 niklas niklas  34M Jan  1  1970 000004.log
-r--r--r-- 1 niklas niklas  11M Jan  1  1970 000005.ldb
-r--r--r-- 1 niklas niklas   16 Jan  1  1970 CURRENT
-r--r--r-- 1 niklas niklas    0 Jan  1  1970 LOCK
-r--r--r-- 1 niklas niklas  199 Jan  1  1970 LOG
-r--r--r-- 1 niklas niklas   50 Jan  1  1970 MANIFEST-000002

You have some +w there which is different from what I have. But still not sure why your machine can open LOCK given that it is -r--r--r--.

from core-kythe.

mpickering avatar mpickering commented on May 7, 2024

Are you using nix or nixos?

from core-kythe.

nh2 avatar nh2 commented on May 7, 2024

@mpickering Nix on Ubuntu

from core-kythe.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.