Laboratory 1

Laboratory 1 Notes »

Subjects

Laboratory Assignments

  1. Get from /etc/passwd all usernames that end in 'x' or 'z'. Redirect the output to output.txt file.
  2. (BONUS) Using output.txt we want to write at the beging of the file the following "Am gasit utilizatorii:". In output.txt we have usernames that respect the following format 'firstname.lastname'. We want to change the 'lastname' of the user on the 4th row with the following: "mylastname".

References

Lecture Notes - Course 1 »

Contact

E-mail: stefan.negru at infoiasi.ro

Please use the following Subject field format of your emails concerning this laboratory: [CN] Message Title

Evaluation

The final grade is calculated using the following formula:
N = 0.3 * P + 0.4 * T + 0.2 * L + 1.

Where:

Important

In order to pass, each student must obtain minimum 5 points for P and T components.

More Details »

Creative Commons License

Laboratory 2

Laboratory 2 Notes »

Subjects

Laboratory Assignments

  1. Compile,execute and explain the examples on the Course 2 Webpage
  2. Create a program that will run in the background, and from 3 in 3 seconds will write a random number in a file. Details of implementation: the parent process will wait SIGUSR1 signal appearance, then it will create a child process, this will be the one that it will write in the file, the parent will wait for child process execution, at which point a message will be displayed.

References

Lecture Notes - Course 2 »

Laboratory 3

Mandatory Assignment - due until Laboratory 4 Laboratory 3 Notes »

Subjects

Laboratory Assignments

  1. Compile,execute and explain the examples on the Course 3 Webpage
  2. Write a program that uses a single pipe for communication and in which:
    • parent process writes a number in the pipe (read from the keyboard)
    • child process checks if the number is prime and transmits the parent process the response (yes/no)
    • parent process will display the response
  3. Write a program to simulate the command: cat / etc / passwd | grep "account name"> account.txt, using FIFO's and duplications. Account name will read from the keyboard.
  4. (BONUS) Implement a program to determine the maximum capacity of a pipe.

References

Lecture Notes - Course 3 »

Laboratory 4

Laboratory 4 Notes »

Laboratory Assignments

  1. Compile,execute and understand the example soketpair.c on the Course 4 Webpage
  2. Create a program in which a father process divides an arithmetic expression in a number of subexpressions. These subexpressions are each evaluated by a child process. The result is returned to the parent process, which will review the expression and return the final result. Communication will be implemented using socketpair().

Mandatory Assignment Evaluation

Implement the following inter-process communication protocol:

Important

Assignment is due Laboratory 4.

Lecture Notes - Course 4 »

Laboratory 5

Project Technical Report - due until Laboratory 7 Laboratory 5 Notes »

Subjects

Laboratory Assignments

  1. Compile,execute and understand the example on the Course 5 Webpage
  2. (BONUS) Modify the example above such that the clients will be processed concurrently using fork(). Watch out for zombie processes.
  3. Develop a TCP server which upon receiving a number from a client, will return the incremented number to the client along with the client number.
  4. Considering a configuration file using the following: (key:command):(e.g. 1111: /bin/ls: 2222: /bin/pwd: 3333:/bin.ps:). Develop a TCP server which will execute the command associate with a known key recieved from a client, anything else will return "Unknown key".

References

Technical Report

Each chosen project must have a technical report associated with it. Until Laboratory 7 you must complete the following:

Lecture Notes - Course 5 »

Laboratory 6

Laboratory 6 Notes »

Subjects

Laboratory Assignments

  1. Considering a configuration file using the following: (key:command):(e.g. 1111: /bin/ls: 2222: /bin/pwd: 3333:/bin.ps:).
    • Develop a concurrent TCP server which will execute the command associate with a known key recieved from a client, anything else will return "Unknown key".
    • The client will display the result of the given command.
    • The server will keep a history of the keys recieved from a client and will have a key associated with the history commad.
  2. Adapt the mandatory assignment from Laboratory 4, so that the communication is done in a concurrent manner between a server and a number of clients.

References

Lecture Notes - Course 6 »

Laboratory 7

Laboratory 7 Notes »

Laboratory Assignments

  1. Compile,execute and understand the example on the Course 7 Webpage
  2. Consider de exercises from Laboratory 5 and develop a UDP server/client instead of a TCP server/client.

Examples of technical reports/scientific articles(in .pdf format)

Example 1
Example 2
Example 3

Mandatory Assignment Evaluation - Technical Report

Each chosen project must have a technical report associated with it. Until Laboratory 7 you must complete the following:

Technical Report recommended format - Springer LNCS

Important

Assignment is due Laboratory 7.

Lecture Notes - Course 7 »

Laboratory 8


Midterm - Project Work

Work on the project. Follow the guidelines:

Projects List »

Laboratory 9


Project Work.

Work on the project. Projects List »

Review Resurse Web in Romanian.

The Laboratory will be held during week 10 as 1st December is Romania National Day.


Lecture Notes - Course 9 »

Laboratory 10

Laboratory 9 Notes »

Subjects

Laboratory Assignments

  1. Develop a program which will wait 6 seconds and 45 microseconds for the user to write something from the keyboard.
  2. Develop a minichat which will use select() for handling sockets and descriptors.(hint: the server will use select to handle clients)
  3. (2*BONUS) Solve the bug from the example provided in Course 9 Webpage. The bug appears when we connect the client to the server and no input is provided, and instead "CTRL + C" is pressed.

References

Lecture Notes - Course 10 »

Laboratory 11

Laboratory 10 Notes » and Laboratory 11 Notes »

Subjects

Laboratory Assignments

  1. Using the minichat developed during Laboratory 10, develop a mechanism for handling OOB data by considering the following:
    • a client with administrator rights and can notify the server to send to another client (which does not have administrator rights) an OOB byte;
    • when the client(the one that does not have administrator rights) recieves the OOB byte it will disconnet from the server.
  2. Verify if the ports 8011 and 6089 are open on www.uaic.ro or www.emag.ro. Find the IP address of the websites using getaddrinfo().

References

Lecture Notes - Course 11 »

Laboratory 12

Recuperare Laborator 12

Laboratoarele din saptamana 12 ( 22 Decembrie 2011 ) se vor recupera vineri 16 Decembrie 2011 dupa cum urmeaza:

  • Grupa B6 - C403 - orele 1000 - 1200;
  • Grupa B7 - C409 - orele 1200 - 1400;
  • Grupa A7 - C409 - orele 1400 - 1600.

Referatele vor fi predate pana pe 22 Decembrie 2011 (ora 2300) prin e-mail la adresa: stefan.negru at infoiasi.ro in format electronic. In saptamana 13 (12 Ianuarie 2012) vor fi predate in format printat.

Laboratory 12 Notes »

Subjects

Laboratory Assignments

  1. Considering a configuration file using the following: (key:command):(e.g. 1111: /bin/ls: 2222: /bin/pwd: 3333:/bin.ps:).
    • Develop a concurrent TCP server that makes use of threads which will execute the command associate with a known key recieved from a client, anything else will return "Unknown key".
    • The client will display the result of the given command.
    • The server will keep a history of the keys recieved from a client and will have a key associated with the history commad.
  2. (2*BONUS)Consider a producer/consumer scenario:
    • The producer generates numbers from 1 to 10 in a random interval (between 0 and 100 milisec.) and stores them in a var.
    • Each consumer will read the numbers from the producer and display them on the screen.

References

Lecture Notes - Course 12 »

Laboratory 13

Prezentari Referate

Referatele vor fi predate pana pe 22 Decembrie 2011 (ora 2300) prin e-mail la adresa: stefan.negru at infoiasi.ro in format electronic. In saptamana 13 (12 Ianuarie 2012) vor fi predate in format printat.

Project Presentations.

Work on the project. Projects List »

Papers (referate) presentations.


Lecture Notes - Course 13 »

Laboratory 14

Project Presentations.


Work on the project. Projects List »


Lecture Notes - Course 14 »

Laboratory 15

Project Presentations.


Work on the project. Projects List »


Lecture Notes - Course 15 »

Laboratory 16

Project Presentations. (only A type projects)

Laboratory Project Evaluation

Evaluarea proiectelor de laborator din saptamana 16 va avea loc la data de 30.01.2012 intre orele:

  • 0830 -1130C401

Vor fi evaluate doar proiectele de clasa A.

Laboratory Project Re-evaluation

Re-evaluarea proiectelor de laborator va avea loc la data de 13.02.2012 intre orele:

  • 0800 -1100C401

Va fi o penalizare de 1,5 puncte.

Proiectele de categorie C care aduc un plus de functionalitatea fata de cerinta initiala, vor fi luate spre evaluare.

Written Test

Testul Scris 30.01.2012

  • 1200 -1400anul II A
  • 1400 -1600anul II B
  • Locatie: C2, C112, C309

Written Test Re-evaluation

Testul Scris Restanta 13 Februarie 2012 Ora 1100, Locatie:C2, C112, C309

Obs. Salile se mai pot modifica in functie de disponibilitate. Modificarile vor fi anuntate pe pagina cursului.
Lecture Notes - Course 16 »