数据库设计代写 | CS848 The Linux Files as a (MM) Database Assignment 1

本次加拿大代写主要为数据库设计相关的assignment

Abstract

The goal of this assignment is to try out the approaches and tools discussed in class on a real-world
example: a subsystem of an existing code base of the Linux system that is related to les managed by
the system.

Logical Schema Description

The logical predicate in the schema is the

file(fileid; fname; size; permissions; user; group)

table that is then specialized to

directory(fileid; fileid)
symlink(fileid; fileid)
blockdevice(fileid; number)
chardevice(fileid; number)

tables, each containing les of the appropriate type. As an initial variant of fileid one can consider the
path from the root of the lesystems (\/”). One can assume that the above tables are paiwise disjoint,
but there could be les not belonging to any of these tabls. An alternative (more ecient) variants will
be discussed below.

Physical Schema Description

The physical predicates (access paths) consist of the following system calls:

int open(const char *pathname, int flags, mode t mode)
int fstat(int fd, struct stat *statbuf)
ssize t readlinkat(int dirfd, const char *pathname, char *buf, size t bufsiz)
struct dirent *readdir(DIR *dirp)

DIR *fdopendir(int fd)

These syscalls will correspond to access paths in your physical design, perhaps with appropriate binding
pattern annotations. For example, the int open(const char *pathname, int flags, mode t mode)
call will (likely) yield an access path
openfile(path; fd)=2=1;

a relation that contains pairs paths and (open) le descriptors.
Detailed descriptions of these syscalls and their parameters are available in the Linux man pages. One
can, in addition, assume the presence of access paths that manipulate strings (such as string concatena-
tion), and access paths that dereference pointers and extract elds from structs as discussed in class.
You are also welcome to explore other Unix/Linux syscalls if you nd that advantageous (but you will
need to document/explain why you have chosen them).

Deliverables

Your task is twofold:

1. rst, de ne a logical and physical schema (as a set of constraints) that captures the above situation;
this includes specifying the appropriate binding patterns for the physicel design (such as \one can
only dereference a pointer to a value when given such a pointer as an input parameter”); The

2. second, describe the C code that will accompany the access paths derived from the above system calls:
this can be done either informally (as a pseudocode) or as a C source (in terms of get first xxx()
and get next xxx() iterators and perhaps initialization code).

The constraints in your design should capture the modelled situation as closely as possible, in particular,
you want to think where keys and functional constraints are appropriate/needed (for example when elds
are extracted from the structs).


程序代写代做C/C++/JAVA/安卓/PYTHON/留学生/PHP/APP开发/MATLAB


本网站支持淘宝 支付宝 微信支付  paypal等等交易。如果不放心可以用淘宝交易!

E-mail: itcsdx@outlook.com  微信:itcsdx


如果您使用手机请先保存二维码,微信识别。如果用电脑,直接掏出手机果断扫描。

blank

发表评论