afancy
unread,Oct 6, 2009, 5:55:25 AM10/6/09Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Disco-development
Hi, when I use homedisco to run locally, it creates the output path "/
srv/disco/data/localhost/65/disco_tut@1254822448", however in
homedisco.py, the path is /srv/disco/f1/disco_tut@1254822815/part-
disco-000000000:1
############### Error thrown #################
OSError: [Errno 2] No such file or directory: '/srv/disco/f1/
disco_tut@1254822815/part-disco-000000000:1'
File "/home/xiliu/workspace/etlonmapred/pygrametlexa/
pygrametlmapreduce.py", line 371, in <module>
main()
File "/home/xiliu/workspace/etlonmapred/pygrametlexa/
pygrametlmapreduce.py", line 358, in main
params=Params(pgcopybulkloader=pgcopybulkloader)
File "/usr/lib/python2.5/site-packages/homedisco.py", line 53, in
new_job
disco_worker.op_map(req)
File "/usr/lib/python2.5/site-packages/disconode-0.1-py2.5.egg/
disconode/disco_worker.py", line 402, in op_map
File "/usr/lib/python2.5/site-packages/disco-0.1-py2.5.egg/disco/
util.py", line 13, in msg
(c, t, job_name, job_input, m)
File "/usr/lib/python2.5/site-packages/homedisco.py", line 25, in
write
self.out = parse_dir(addr)
File "/usr/lib/python2.5/site-packages/homedisco.py", line 9, in
parse_dir
for f in os.listdir(LOCAL_PATH + path):
############# Output path ########################
afancy@afancy-fedora:/srv/disco/data/localhost/65/
disco_tut@1254822448$ pwd
/srv/disco/data/localhost/65/disco_tut@1254822448
afancy@afancy-fedora:/srv/disco/data/localhost/65/
disco_tut@1254822448$ ls
part-disco-000000000 part-disco-000000001
afancy@afancy-fedora:/srv/disco/data/localhost/65/
disco_tut@1254822448$
########## it throws error when os.listdir(LOCAL_PATH + path)
###################
def parse_dir(dir):
x, x, LOCAL_PATH = util.load_conf()
x, x, x, mode, path = dir.split("/", 4)
res = []
for f in os.listdir(LOCAL_PATH + path):
if not (f.startswith(mode) or "." in f):
continue
proto = f.split("-")[1]
if proto == "chunk":
res.append("chunkfile://%s%s" % (path, f))
elif proto == "disco":
res.append("disco://localhost/%s%s" % (path,
f))
return res
>>> os.listdir(LOCAL_PATH +path)
Traceback (most recent call last):
File "<string>", line 1, in <fragment>
OSError: [Errno 2] No such file or directory: '/srv/disco/65/
disco_tut@1254822448/part-disco-000000000:1'
>>>