owned this note
owned this note
Published
Linked with GitHub
1. "The goal is a Christmas launch, so timely delivery is critical for this MVP (no deadline extensions).".... This is written in the Introduction section of the Course project doc. Does this mean we cannot use late days?
2. Say one client is editing a particular file while someone else is streaming the same file. How shall it output?
3. ```[10] Get Additional Information: Users can access a wealth of supplementary information about specific files. This includes details such as file size, access rights, timestamps, and other metadata, providing users with comprehensive insights into the files they interact with.```
What does `timestamps` mean in this case?
4. In example 4: write to a file: ```Client: WRITE mouse.txt 2 # Inserting a sentence delimiter
Client: 5 and AAD. aaaah # New sentences : [I dont like T-T PNS and AAD.]* [aaaah]. Currently active status remains with the index at index 2
Client: 0 But, # New sentence : [But, I dont like T-T PNS and AAD.]* [aaaah].
Client: ETIRW
Write Successful!```, shouldn't the sentence number be 1 and not 2 in the WRITE command? (because up until the previous line, we havent added a delimiter to sentence 1) and the active status also remains at sentence number 1 right?
5. In Example 10: Access Control: ```Client: ADDACCESS -W nuh_uh.txt user3
Access granted successfully!
--> File: feedback.txt
--> Owner: user1
--> Created: 2025-10-10 14:21
--> Last Modified: 2025-10-10 14:32
--> Size: 52 bytes
--> Access: user1 (RW), user2 (RW)
--> Last Accessed: 2025-10-10 14:32 by user1```, isn't "File:" supposed to display the file's name (which is nuh_uh.txt)? and in "Access:" why isn't user3 added (assuming there exists user3 coz the message says "Access granted successfully")?
6. ```After each sentence write update, the index must word_index must update for the next sentence.``` Could you please explain what this sentence means
7. Just to confirm, -W flag would provide BOTH read and write access to the user right?
8. Referring to the word-index in example 4. Should we take it as 0-indexed or 1-indexed? And is the index referring to a particular word or the positions between the words? For example, say a sentence has "A B C D E" will "1 Z" result in "A Z B C D E" and 0 Z result in "Z A B C D E"? There are 4 cases of inserting a word using word index in example 4, sentence 0 word 4 and word 6, and sentence 1 word 5 and word 0, and the policy for inserting words doesn't match in all the cases.
9. Under Bonus Functionalities, in Hierarchical Folder Structure, is the structure created by a user expected to be persistent? i.e. when the user logs back in, he should start off with the folder structure he left with?
10. Under Bonus Functionalities, do checkpoints need to be persistent? Also, are checkpoints file specific or user specific?
11. It is mentioned that ```Reading, Writing, Streaming : The NM identifies the correct Storage Server and returns the precise IP address and client port for that SS to the client. Subsequently, the client directly communicates with the designated SS.```
How exactly does NM identifies the correct SS for the client (in case there are multiple SS hosting the same file)?
12. Lets consider File1 is in SS1 and File2 is in SS2. Say direct connection between SS1 and client is established. Now if client wants to access File2 will a new connection establish between SS2 and client or will it just say file not exists?
13. What exactly does it mean by sending a predefined STOP packet? Does it mean that the user has to send a STOP packet explicitly, or after read, write or stream task is completed, it automatically terminates the connection?
14. Do we have to define each data blocks size and the number of data blocks in the storage? Also, is there any restriction on the storage capacity of each storage server?
15. In example 4,
```
Client: READ mouse.txt
Im just a deeply mistaken hollow pocket-sized lil gei-fwen mouse. I dont like T-T PNS
Client: WRITE mouse.txt 1 # Inserting a sentence delimiter
Client: 5 and AAD. aaaah # New sentences : [I dont like T-T PNS and AAD.]* [aaaah]. Currently active status remains with the index at index 1
Client: 0 But, # New sentence : [But, I dont like T-T PNS and AAD.]* [aaaah].
Client: ETIRW
Write Successful!
Client: READ mouse.txt
Im just a deeply mistaken hollow pocket-sized lil gei-fwen mouse. But, I dont like T-T PNS and AAD. aaaah.
```
Why has there been a delimiter added at the end of `aaaah`?
16. Should we include LLM Generations with the files?
17. 
this was shown in the tut online explanation, just wanted to make it clear
does it work like, lets say it was
[S1->hello->folks
S2-> hows->life
so on ..]
I want to insert the following after hello
S->hi
S'->!
S''->!
so will the final be
[
S1-> hello hi
!
! folks
]
is this correct?
18. does backup start automatically when we connect one of the storage server, or does that also require explicit connection. for eg: if I start storage server 1, does the backup for it start automatically, or I need to start its backup also myself?
19. For READ/WRITE/STREAM operations: After NM gives SS details to client, should the client open a new TCP socket to SS?
Should SS have two
ening ports: one for NM, one for clients?
20. How exactly is a user trying to write affected when there are >=1 readers or streamers? For example, if the user is trying to commit his write while the file is being read/streamed. Should this request be queued after the reads/streams? Or should the writer be given priority by interrupting the readers/streamers?
21. Till what extent are we expected to handle packet loss? Can we assume no "ACK"s will be lost or are we supposed to handle loss of ACKs as well? Please clarify the extent of error handling for the networking side of things.
22. The 5 marks of bonus will be granted based on how we implement the project specifications or will they also be granted based on new/extra features we devise?
23. Undo Change: Users can rever the last changes made to a file. does this mean that if i do WRITE <some sentences> and then i do ETIRW and after that when i undo it removes ALL the sentences that were written by WRITE? Also if i do undo again, should it restore the sentences or undo whatever change was made before that or do nothing?
24. `Client: WRITE mouse.txt 1 # Inserting a sentence delimiter
Client: 5 and AAD. aaaah # New sentences : [I dont like T-T PNS and AAD.]* [aaaah]. Currently active status remains with the index at index 1
Client: 0 But, # New sentence : [But, I dont like T-T PNS and AAD.]* [aaaah].`
Here, if I try the command : `Client: 9 abcd`
Should I get an error because I'm referencing next sentence or should it succeed?
25. The SS sends a list of files on it when it registers. Can we assume that 4096 bytes is enough for a very long list?
26. Should we Load ALL files at server startup (slower startup, all files always ready)or do Lazy loading - load file on first access, keep in memory once loaded (faster startup) what to do?
27. Are the shell commands in the file to be EXEC'd singular commands? Or can they include pipes, background &s etc?
28. If access is attempted to be given to a user that is not registered (does not show up in
), should we give an error?
29. Is cjson header allowed to be used?
30. If a library is not posix, is it allowed to be used?
31. Following up on 27., they can be commands other than bash also? Please clarify 'shell commands'. They need not be bash commands? So they can be READ, WRITE, STREAM, CREATEFOLDER etc.?
32. For the EXEC operation, do we have to separately interpret the file and then send for execution? For example, let a series of WRITE operations lead to the file `hi.txt` have `echo hiii. ls`. Is the expected output:
`hiii
\n<
of files in directory>`
or `hiii.
\n<list of files in directory>`
or `hiii. ls`
33. For EXEC operation, are we supposed to send request from client to ns, then fetch the file from ss and execute them on ns itself? So this flow has to be different from the normal READ and WRITE operations right? And should the whole file be treated as a bash script? Or we have to parse it sentence by sentence?
34. Is the undo command supposed to store only one level of history, or is the code supposed to support multiple simultaneous undos chained together?
35. When we are implementing WRITE, do we add a newline after adding each sentence? According to example 2, yes. According to example 4, no. So what do we do?
36. I have 2 clients alice and bob, and then quit the client alice in the alice server, and then run LIST from the bob server. Should the output be:
-->alice
-->bob
since alice was technically registered before? or does the output change to:
-->bob
37. In the document it is mentioned "At any point, there would be a single instance of the Name Server running, to which multiple instances of Storage Servers and User Clients can connect. The User Clients and Storage Servers can disconnect and reconnect at any time, and the system should handle these events gracefully."
My question - Does NM need to be able to disconnect using ctrl+c? or is stopping it using ctrl+z fine, as the exiting of this server is not mentioned in the project document?
38. If the owner is attempting to delete a file, but the file is being written to by another user, are we expected to:
a) Prevent the owner from deleting with an error message?
b) Give an error message to the editing user?
39. In the 23rd answer you have mentioned that multiple undoes are supported for one file while the project doc explicitly states they are not(under example 5)?!
40. For performing UNDO, does a user need to have write permission for that file?
41. What is expected to be done in caching? Does it need to be implemented on the ns or ss? As on the ns, it would just involve caching the storage server id for the corresponding file, whose access is already O(1) or O(log n) average case.
42. can we use glibc?
43. do access lookups also need to be fast?
44. If a user is writing to a file and has a sentence locked, but the client disconnects midway, should other users be allowed to write to that sentence? Do we leave the sentence as locked until the previously disconnected user writes that sentence again?
45. For running the EXEC command, Example 11 in the document shows commands being separated by newline characters. Is that how the file should be in our document as well? Or separated based on sentence delimiters, as that is how sentences are handled in the writing of files?
For example:
"ls
echo "Hello"
or "ls. echo "Hello".
46. Can we assume that WRITE to a file will always happen via terminal ONLY and not directly to the file? If only through terminal, then how to add newline characters to the file?
47. For blocking operations like EXEC on the Name Server and WRITE on the Storage Server, is it acceptable to let the main epoll thread block, or are we required to implement a thread pool to handle them asynchronously?
48. only file-lookups need to be efficient?
49.
Client: READ mouse.txt
Im just a mouse. I dont like T-T PNS
Client: WRITE mouse.txt 0 # Inserting multiple times into a sentence
Client: 4 deeply mistaken hollow lil gei-fwen # New sentence : Im just a deeply mistaken hollow lil gei-fwen pocket-sized mouse.
Client: 6 pocket-sized # New sentence : Im just a deeply mistaken hollow pocket-sized lil gei-fwen mouse.
Client: ETIRW
Write Successful!
Client: READ mouse.txt
Im just a deeply mistaken hollow pocket-sized lil gei-fwen mouse. I dont like T-T PNS
The words for sentence(0) are : (0) Im (1) just (2) a (3) mouse. I dont like T-T PNS
shouldn't the second line of input be "Client: 3 deeply mistaken hollow lil gei-fwen" instead of client: 4 ?
50. in q43, we are expected to implement caching for access lookups as well???
51. lets say a client 1 is writing to a file at sentence index 1 so logically other client 2 must give sentence is locked for writing at index 1, but should it give the same for index 2 or it should be able to write at any other index except for 1. also can client 2 read the file while client 1 is writing.
52. Suppose client 2 is in a WRITE session to a file whose owner is client 1. While client 2 is writing, client 1 removes the file access to client 2. Should that write session succeed or not?
53. lets say:
WRITE file.txt 0
1 hello
2 ww
ETIRW
WRITE file.txt 0
1 finally !
ETIRW
WRITE file.txt 1
1 demn
ETIRW
what should the output of this be?
is it- finally hello ww! demn
or is it- finally! demn hello ww
pls confirm asap
54. For STREAM, is it fine, if there is no gap between the words printed?