
**Describe the unexpected behaviour**
Trying to install clickhouse in FreeBSD (pfsense firewall), following this [link ](https://clickhouse.com/#quick-start)

**How to reproduce**
1 - copy the ClickHouse file into pfsense from [here](https://builds.clickhouse.com/master/freebsd/clickhouse)
2 - chmod a+x ./clickhouse
3 - sudo ./clickhouse install

 **Which ClickHouse server version to use**
- 21.12.1.8928 (official build


**Error message and/or stacktrace**
Code: 107. DB::Exception: Cannot obtain path to the binary from /proc/self/exe, file doesn't exist. (FILE_DOESNT_EXIST) (version 21.12.1.8928 (official build))
![image](https://user-images.githubusercontent.com/14872281/148040641-26f23fc0-39e9-4dcd-97dc-860c9cdefb9b.png)


"clickhouse-compressor",
            "clickhouse-format",
            "clickhouse-extract-from-config"
        };
        for (const auto & tool : tools)
        {
            bool need_to_create = true;
            fs::path symlink_path = bin_dir / tool;
            if (fs::exists(symlink_path))
            {
                bool is_symlink = fs::is_symlink(symlink_path);
                fs::path points_to;
                if (is_symlink)
                    points_to = fs::weakly_canonical(fs::read_symlink(symlink_path));
                if (is_symlink && points_to == main_bin_path)
                {
                    need_to_create = false;
                }
                else
                {
                    if (!is_symlink)
                    {
                        fs::path rename_path = symlink_path.replace_extension(".old");
                        fmt::print("File {} already exists but it's not a symlink. Will rename to {}.\n",
                                   symlink_path.string(), rename_path.string());
                        fs::rename(symlink_path, rename_path);
                    }
                    else if (points_to != main_bin_path)
                    {
                        fmt::print("Symlink {} already exists but it points to {}. Will replace the old symlink to {}.\n",