#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>

int main(int argc, char *argv[])
{
    char buff[256];

    snprintf(buff, 256, "/dev/hd%c", argv[1][0]);
    execl("/usr/sbin/smartctl", "/usr/sbin/smartctl", "-a", buff, NULL);
}


