Index: uspace/lib/c/include/ipc/vfs.h
===================================================================
--- uspace/lib/c/include/ipc/vfs.h	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/lib/c/include/ipc/vfs.h	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -94,4 +94,5 @@
 	VFS_OUT_UNMOUNT,
 	VFS_OUT_UNMOUNTED,
+	VFS_OUT_GET_SIZE,
 	VFS_OUT_SYNC,
 	VFS_OUT_STAT,
Index: uspace/lib/fs/libfs.c
===================================================================
--- uspace/lib/fs/libfs.c	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/lib/fs/libfs.c	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -238,4 +238,25 @@
 }
 
+static void vfs_out_get_size(ipc_callid_t rid, ipc_call_t *req)
+{
+	service_id_t service_id = (service_id_t) IPC_GET_ARG1(*req);
+	fs_index_t index = (fs_index_t) IPC_GET_ARG2(*req);
+	int rc;
+
+	fs_node_t *node = NULL;
+	rc = libfs_ops->node_get(&node, service_id, index);
+	if (rc != EOK) {
+		async_answer_0(rid, rc);
+	}
+	if (node == NULL) {
+		async_answer_0(rid, EINVAL);
+	}
+	
+	uint64_t size = libfs_ops->size_get(node);
+	libfs_ops->node_put(node);
+	
+	async_answer_2(rid, EOK, LOWER32(size), UPPER32(size));
+}
+
 static void vfs_connection(ipc_callid_t iid, ipc_call_t *icall, void *arg)
 {
@@ -299,4 +320,7 @@
 			vfs_out_sync(callid, &call);
 			break;
+		case VFS_OUT_GET_SIZE:
+			vfs_out_get_size(callid, &call);
+			break;
 		default:
 			async_answer_0(callid, ENOTSUP);
@@ -657,10 +681,12 @@
 	/* Find the file and its parent. */
 	
+	unsigned last_next = 0;
+	
 	while (next != last) {
 		if (cur == NULL) {
-			async_answer_0(rid, ENOENT);
-			LOG_EXIT(ENOENT);
-			goto out;
-		}
+			assert(par != NULL);
+			goto out1;
+		}
+
 		if (!ops->is_directory(cur)) {
 			async_answer_0(rid, ENOTDIR);
@@ -669,4 +695,5 @@
 		}
 		
+		last_next = next;
 		/* Collect the component */
 		rc = plb_get_component(component, &clen, &next, last);
@@ -773,7 +800,12 @@
 		rc = ops->unlink(par, cur, component);
 		if (rc == EOK) {
-			aoff64_t size = ops->size_get(cur);
+			int64_t size = ops->size_get(cur);
+			int32_t lsize = LOWER32(size);
+			if (lsize != size) {
+				lsize = -1;
+			}
+			
 			async_answer_5(rid, fs_handle, service_id,
-			    ops->index_get(cur), LOWER32(size), UPPER32(size),
+			    ops->index_get(cur), last, lsize,
 			    ops->is_directory(cur) ? VFS_NODE_DIRECTORY : VFS_NODE_FILE);
 			LOG_EXIT(EOK);
@@ -819,8 +851,13 @@
 	
 	/* Return. */
-	
+out1:
 	if (!cur) {
+		async_answer_5(rid, fs_handle, service_id,
+			ops->index_get(par), last_next, -1, VFS_NODE_DIRECTORY);
+		LOG_EXIT(EOK);
+		/*
 		async_answer_0(rid, ENOENT);
 		LOG_EXIT(ENOENT);
+		*/
 		goto out;
 	}
@@ -835,7 +872,12 @@
 	}
 	
-	aoff64_t size = ops->size_get(cur);
+	int64_t size = ops->size_get(cur);
+	int32_t lsize = LOWER32(size);
+	if (lsize != size) {
+		lsize = -1;
+	}
+	
 	async_answer_5(rid, fs_handle, service_id,
-		ops->index_get(cur), LOWER32(size), UPPER32(size),
+		ops->index_get(cur), last, lsize,
 		ops->is_directory(cur) ? VFS_NODE_DIRECTORY : VFS_NODE_FILE);
 	
Index: uspace/srv/vfs/vfs.h
===================================================================
--- uspace/srv/vfs/vfs.h	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/srv/vfs/vfs.h	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -113,5 +113,5 @@
 	vfs_node_type_t type;	/**< Partial info about the node type. */
 
-	aoff64_t size;		/**< Cached size if the node is a file. */
+	int64_t size;		/**< Cached size if the node is a file. */
 
 	/**
@@ -185,4 +185,5 @@
 extern unsigned vfs_nodes_refcount_sum_get(fs_handle_t, service_id_t);
 
+int64_t vfs_node_get_size(vfs_node_t *node);
 
 #define MAX_OPEN_FILES	128
Index: uspace/srv/vfs/vfs_lookup.c
===================================================================
--- uspace/srv/vfs/vfs_lookup.c	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/srv/vfs/vfs_lookup.c	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -270,4 +270,11 @@
 	}
 	
+	unsigned last = IPC_GET_ARG3(answer);
+	if (last != first + len) {
+		/* The path wasn't processed entirely. */
+		rc = ENOENT;
+		goto out;
+	}
+	
 	if (!result) {
 		rc = EOK;
@@ -278,6 +285,5 @@
 	result->triplet.service_id = (service_id_t) IPC_GET_ARG1(answer);
 	result->triplet.index = (fs_index_t) IPC_GET_ARG2(answer);
-	result->size =
-	    (aoff64_t) MERGE_LOUP32(IPC_GET_ARG3(answer), IPC_GET_ARG4(answer));
+	result->size = (int64_t)(int32_t) IPC_GET_ARG4(answer);
 	result->type = IPC_GET_ARG5(answer);
 	rc = EOK;
Index: uspace/srv/vfs/vfs_node.c
===================================================================
--- uspace/srv/vfs/vfs_node.c	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/srv/vfs/vfs_node.c	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -45,4 +45,5 @@
 #include <async.h>
 #include <errno.h>
+#include <macros.h>
 
 /** Mutex protecting the VFS node hash table. */
@@ -300,4 +301,20 @@
 }
 
+int64_t vfs_node_get_size(vfs_node_t *node)
+{
+	if (node->size == -1) {
+		sysarg_t sz1 = 0;
+		sysarg_t sz2 = 0;
+		
+		async_exch_t *exch = vfs_exchange_grab(node->fs_handle);
+		(void) async_req_2_2(exch, VFS_OUT_GET_SIZE,
+			node->service_id, node->index, &sz1, &sz2);
+		vfs_exchange_release(exch);
+		
+		node->size = MERGE_LOUP32(sz1, sz2);
+	}
+	return node->size;
+}
+
 /**
  * @}
Index: uspace/srv/vfs/vfs_ops.c
===================================================================
--- uspace/srv/vfs/vfs_ops.c	(revision b7c62a99d8505fbceabebd8655bcb200d89ed7c0)
+++ uspace/srv/vfs/vfs_ops.c	(revision 677745a8f02a62fcdda400d24b3f38e1b8940077)
@@ -840,5 +840,5 @@
 	} else {
 		if (file->append)
-			file->pos = file->node->size;
+			file->pos = vfs_node_get_size(file->node);
 		
 		rc = async_data_write_forward_4_1(fs_exch, VFS_OUT_WRITE,
@@ -942,5 +942,5 @@
 	case SEEK_END:
 		fibril_rwlock_read_lock(&file->node->contents_rwlock);
-		aoff64_t size = file->node->size;
+		aoff64_t size = vfs_node_get_size(file->node);
 		
 		if ((off >= 0) && (size + off < size)) {
