-
-
Notifications
You must be signed in to change notification settings - Fork 606
Closed
Description
While running nginx and testing achievable requests/s for its internal server_status page (e.g. no file access should be required for that), I noticed that req/s drops with elapsed time. Problem is that nginx was writing to access.log (so obvious). Problematic part in OSv code is https://github.com/cloudius-systems/osv/blob/master/fs/ramfs/ramfs_vnops.cc#L393:
void *new_buf = malloc(new_size);
...
if (np->rn_size != 0) {
memcpy(new_buf, np->rn_buf, vp->v_size);
free(np->rn_buf);
}
In my case is 90 B long line written per HTTP request, and in short time this requires malloc/memcpy/free of about 50 MB.