HarryWei / cloudxy

Automatically exported from code.google.com/p/cloudxy
6 stars 3 forks source link

Under HLFS hdfs mode, we cannot boot a VM correctly #36

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. git clone git://git.qemu.org/qemu.git
2. cd qemu
3, git reset --hard v1.3.0
4. wget 
http://cloudxy.googlecode.com/svn/trunk/hlfs/patches/hlfs_driver_for_qemu_1.3.0.
patch 
5. git apply hlfs_driver_for_qemu_1.3.0.patch
6, Modify the dead path
7, ./configure 
8, make
9, sudo make install
10, wget http://cloudxy.googlecode.com/files/linux-0.2.img.zip
11, unzip linux-0.2.img.zip 
12, hadoop fs -mkdir /tmp/testenv
13, qemu-img convert linux-0.2.img  hlfs:hdfs:///tmp/testenv/testfs
14, qemu-system-x86_64 -m 512 -drive file=hlfs:hdfs:///tmp/testenv/testfs

What is the expected output? What do you see instead?
Expected output:
create this base linux os correctly.

See instead:
[...]
read block from seg:0#9915708 size:8192
read len 1024
** Message: leave func hlbs_read
** Message: enter func hlbs_read
Hlfs Read Req 
pos:10148864,read_len:4096,last_segno:0,last_offset:18168213,cur_file_len:194001
92
read offset:10148864,read len:4096
need to read muti block
need to read first block
--Entering func dbcache_query_block
block_no 1238 will be queried
NO item in hash table
not find in cache!
storage address:9915708
enter func read_block_fast
offset :9915708,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9915708 size:8192
fist offset:1024
start db: 1239 end db: 1239
need to read last block
--Entering func dbcache_query_block
block_no 1239 will be queried
NO item in hash table
not find in cache!
storage address:9923900
enter func read_block_fast
offset :9923900,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9923900 size:8192
leave func hlfs_read
** Message: leave func hlbs_read
** Message: enter func hlbs_read
Hlfs Read Req 
pos:10152960,read_len:32768,last_segno:0,last_offset:18168213,cur_file_len:19400
192
read offset:10152960,read len:32768
need to read muti block
need to read first block
--Entering func dbcache_query_block
block_no 1239 will be queried
NO item in hash table
not find in cache!
storage address:9923900
enter func read_block_fast
offset :9923900,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9923900 size:8192
fist offset:5120
start db: 1240 end db: 1243
--Entering func dbcache_query_block
block_no 1240 will be queried
NO item in hash table
not find in cache!
storage address:9932092
enter func read_block_fast
offset :9932092,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9932092 size:8192
offset: 13312
--Entering func dbcache_query_block
block_no 1241 will be queried
NO item in hash table
not find in cache!
storage address:9940284
enter func read_block_fast
offset :9940284,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9940284 size:8192
offset: 21504
--Entering func dbcache_query_block
block_no 1242 will be queried
NO item in hash table
not find in cache!
storage address:9948476
enter func read_block_fast
offset :9948476,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9948476 size:8192
offset: 29696
need to read last block
--Entering func dbcache_query_block
block_no 1243 will be queried
NO item in hash table
not find in cache!
storage address:9973229
enter func read_block_fast
offset :9973229,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9973229 size:8192
leave func hlfs_read
** Message: leave func hlbs_read
** Message: enter func hlbs_read
Hlfs Read Req 
pos:10185728,read_len:65536,last_segno:0,last_offset:18168213,cur_file_len:19400
192
read offset:10185728,read len:65536
need to read muti block
need to read first block
--Entering func dbcache_query_block
block_no 1243 will be queried
NO item in hash table
not find in cache!
storage address:9973229
enter func read_block_fast
offset :9973229,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9973229 size:8192
fist offset:5120
start db: 1244 end db: 1251
--Entering func dbcache_query_block
block_no 1244 will be queried
NO item in hash table
not find in cache!
storage address:9981421
enter func read_block_fast
offset :9981421,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9981421 size:8192
offset: 13312
--Entering func dbcache_query_block
block_no 1245 will be queried
NO item in hash table
not find in cache!
storage address:9989613
enter func read_block_fast
offset :9989613,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9989613 size:8192
offset: 21504
--Entering func dbcache_query_block
block_no 1246 will be queried
NO item in hash table
not find in cache!
storage address:9997805
enter func read_block_fast
offset :9997805,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#9997805 size:8192
offset: 29696
--Entering func dbcache_query_block
block_no 1247 will be queried
NO item in hash table
not find in cache!
storage address:10005997
enter func read_block_fast
offset :10005997,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#10005997 size:8192
offset: 37888
--Entering func dbcache_query_block
block_no 1248 will be queried
NO item in hash table
not find in cache!
storage address:10014189
enter func read_block_fast
offset :10014189,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#10014189 size:8192
offset: 46080
--Entering func dbcache_query_block
block_no 1249 will be queried
NO item in hash table
not find in cache!
storage address:10022381
enter func read_block_fast
offset :10022381,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#10022381 size:8192
offset: 54272
--Entering func dbcache_query_block
block_no 1250 will be queried
NO item in hash table
not find in cache!
storage address:10030573
enter func read_block_fast
offset :10030573,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#10030573 size:8192
offset: 62464
need to read last block
--Entering func dbcache_query_block
block_no 1251 will be queried
NO item in hash table
not find in cache!
storage address:10038765
enter func read_block_fast
offset :10038765,segno:0,last_offset:18168213,last_rsegfile_offset:18168213
using pre open read file handler
read block from seg:0#10038765 size:8192
leave func hlfs_read
** Message: leave func hlbs_read
 we should do clean in silent period ;access timestamp:1360340274185,cur timestamp:1360340275491
 we should do clean in silent period ;access timestamp:1360340274185,cur timestamp:1360340276491
 time wait res for cond is :0 !
--total dirty block:1,oldest block no:0--
--blocks_count:1,buff_len:8192--
ib_amount we need 0 ibs
ib_amount we need 0 ibs
 db_cur_no:0 db_offset:25
 is level1 -- db_cur_no:0 db_offset:25
COMPRESSED: db_offset:8217
COMPRESSED: ib_offset:8217
to update inode ...
last offset:18168213 , last segno:0 log head len:25 iboffset:8217
inode address's offset 18176430 , give it 18176430
to fill log header ...
ib_amount we need 0 ibs
enter func update_inode_index
 is level1 -- db_cur_no:0 db_offset:25
-----dbno:0,idx:0, blocks:18168238,db_offset:25
log size:8369,log header:25,inode:136,inode map:16,dbnum:1,ibnum:0
Exception in thread "Thread-4173" org.apache.hadoop.ipc.RemoteException: 
java.io.IOException: Append is not supported. Please see the dfs.support.append 
configuration parameter.
    at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.appendFile(FSNamesystem.java:1455)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.append(NameNode.java:718)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.hadoop.ipc.RPC$Server.call(RPC.java:557)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1439)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1435)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:396)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1278)
    at org.apache.hadoop.ipc.Server$Handler.run(Server.java:1433)

    at org.apache.hadoop.ipc.Client.call(Client.java:1150)
    at org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:226)
    at $Proxy0.append(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:616)
    at org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMethod(RetryInvocationHandler.java:82)
    at org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(RetryInvocationHandler.java:59)
    at $Proxy0.append(Unknown Source)
    at org.apache.hadoop.hdfs.DFSClient.append(DFSClient.java:799)
    at org.apache.hadoop.hdfs.DFSClient.append(DFSClient.java:788)
    at org.apache.hadoop.hdfs.DistributedFileSystem.append(DistributedFileSystem.java:175)
    at org.apache.hadoop.fs.FileSystem.append(FileSystem.java:702)
Call to 
org.apache.hadoop.conf.FileSystem::append((Lorg/apache/hadoop/fs/Path;)Lorg/apac
he/hadoop/fs/FSDataOutputStream;) failed!
**
ERROR:/home/jiawei/workshop3/hlfs/src/logger/segfile_handler_optmize.c:122:prev_
open_wsegfile: assertion failed: (0)
已放弃

Original issue reported on code.google.com by harryxi...@gmail.com on 8 Feb 2013 at 4:38