{
    "version": "https:\/\/jsonfeed.org\/version\/1.1",
    "title": "IT science: заметки с тегом iscsi",
    "_rss_description": "IT science — статьи и инструкции из мира IT",
    "_rss_language": "ru",
    "_itunes_email": "",
    "_itunes_categories_xml": "",
    "_itunes_image": "",
    "_itunes_explicit": "",
    "home_page_url": "https:\/\/itscience.pro\/tags\/iscsi\/",
    "feed_url": "https:\/\/itscience.pro\/tags\/iscsi\/json\/",
    "icon": "https:\/\/itscience.pro\/pictures\/userpic\/userpic@2x.jpg?1658757154",
    "authors": [
        {
            "name": "IT science",
            "url": "https:\/\/itscience.pro\/",
            "avatar": "https:\/\/itscience.pro\/pictures\/userpic\/userpic@2x.jpg?1658757154"
        }
    ],
    "items": [
        {
            "id": "43",
            "url": "https:\/\/itscience.pro\/all\/sozdayom-synology-iscsi-i-podklyuchaem-v-ubuntu\/",
            "title": "Создаём synology iscsi и подключаем в Ubuntu",
            "content_html": "<p>сервер Synology DSM 7.0.1-42218<br \/>\nUbuntu 20.04<\/p>\n<h2>В Synology<\/h2>\n<p>переходим в SAN менеджер и создаем target<\/p>\n<div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134256.png\" width=\"800\" height=\"351.91637630662\" alt=\"\" \/>\n<\/div>\n<p>и сразу создаём, связанный с target LUN<\/p>\n<div class=\"e2-text-picture\">\n<div class=\"fotorama\" data-width=\"671\" data-ratio=\"1.0583596214511\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134406.png\" width=\"671\" height=\"634\" alt=\"\" \/>\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134433.png\" width=\"670\" height=\"636\" alt=\"\" \/>\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134704.png\" width=\"674\" height=\"635\" alt=\"\" \/>\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134720.png\" width=\"669\" height=\"636\" alt=\"\" \/>\n<\/div>\n<\/div>\n<p>нам нужно 30Тб, не заморачиваемся с гибкостью, нужна максимальная надёжность<\/p>\n<p>дальше настраиваем в ubuntu<\/p>\n<h2>в Ubuntu<\/h2>\n<p>устанавливаем софт<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">sudo su\napt update\napt install open-iscsi<\/code><\/pre><p>редактируем конфиг<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">mcedit \/etc\/iscsi\/iscsid.conf<\/code><\/pre><p>меняем<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">#*****************\n# Startup settings\n#*****************\n\n# To request that the iscsi initd scripts startup a session set to &quot;automatic&quot;.\n# node.startup = automatic\n#\n# To manually startup the session set to &quot;manual&quot;. The default is manual.\n#node.startup = manual\nnode.startup = automatic<\/code><\/pre><p>запрашиваем доступные таргеты с сервера<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">iscsiadm -m discovery -t st -p &lt;адрес сервера&gt;<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_160129.png\" width=\"602\" height=\"52\" alt=\"\" \/>\n<\/div>\n<p>когда у нас подключен LUN мы можем заняться созданием раздела и форматированием в btrfs<br \/>\nдля начала посмотрим, куда подключился LUN<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">fdisk -l<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_170905.png\" width=\"685\" height=\"321\" alt=\"\" \/>\n<\/div>\n<p>в нашем примере это \/dev\/sdb<\/p>\n<p>создаем раздел на все свободное пространство (это будет радел GPT, иначе не сможем сделать больше 2 TiB).<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">fdisk \/dev\/sdb<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171013.png\" width=\"800\" height=\"602.10930009588\" alt=\"\" \/>\n<\/div>\n<p>как нам подсказывает помощь, сначала меняем тип раздела, жмём <b>g<\/b>, потом создаем новый раздел <b>n<\/b>, номер раздела 1, он у нас первый и единственный, размеры начала раздела и его конца по-умолчанию. Когда мы все проверили и нас все устроило, жмём <b>w<\/b> и записываем изменения.<\/p>\n<div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171042.png\" width=\"736\" height=\"230\" alt=\"\" \/>\n<\/div>\n<p>ещё раз запускаем fdisk и смотрим результат<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">fdisk -l<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171120.png\" width=\"680\" height=\"400\" alt=\"\" \/>\n<\/div>\n<p>мы получили раздел \/dev\/sdb1<\/p>\n<p>теперь форматируем<br \/>\nдля начала установим btrfs-progs<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">apt install btrfs-progs<\/code><\/pre><p>форматируем наш раздел<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">mkfs.btrfs -L data \/dev\/sdb1<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_172420.png\" width=\"455\" height=\"321\" alt=\"\" \/>\n<\/div>\n<p>подключаем раздел как папку \/var<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">mount \/dev\/sdb1 \/mail<\/code><\/pre><p>смотрим uuid нашего раздела<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">btrfs filesystem show \/mail<\/code><\/pre><div class=\"e2-text-picture\">\n<img src=\"https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_173113.png\" width=\"488\" height=\"65\" alt=\"\" \/>\n<\/div>\n<p>редактируем \/etc\/fstab для автоматического подключения<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">mcedit \/etc\/fstab<\/code><\/pre><p>прописываем<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">UUID=5d84eadf-6272-4b3f-8ac9-90a72108df11       \/mail   btrfs   defaults    0 0<\/code><\/pre><p>перегружаем и проверяем<\/p>\n<pre class=\"e2-text-code\"><code class=\"\">reboot<\/code><\/pre>",
            "date_published": "2021-12-17T14:43:39+03:00",
            "date_modified": "2021-12-17T14:43:21+03:00",
            "tags": [
                "iscsi",
                "synology",
                "ubuntu"
            ],
            "image": "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134256.png",
            "_date_published_rfc2822": "Fri, 17 Dec 2021 14:43:39 +0300",
            "_rss_guid_is_permalink": "false",
            "_rss_guid": "43",
            "_e2_data": {
                "is_favourite": false,
                "links_required": [
                    "jquery\/jquery.js",
                    "fotorama\/fotorama.css",
                    "fotorama\/fotorama.js",
                    "highlight\/highlight.js",
                    "highlight\/highlight.css"
                ],
                "og_images": [
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134256.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134406.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134433.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134704.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_134720.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_160129.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_170905.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171013.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171042.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_171120.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_172420.png",
                    "https:\/\/itscience.pro\/pictures\/izobrazhenie_2021-12-16_173113.png"
                ]
            }
        }
    ],
    "_e2_version": 4171,
    "_e2_ua_string": "Aegea 11.4 (v4171)"
}