Tsung-Jung Tsai (TJ_Tsai)
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.

      Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Explore these features while you wait
      Complete general settings
      Bookmark and like published notes
      Write a few more notes
      Complete general settings
      Write a few more notes
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.

    Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Explore these features while you wait
    Complete general settings
    Bookmark and like published notes
    Write a few more notes
    Complete general settings
    Write a few more notes
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Slurm / Partition === ###### tags: `Slurm` ###### tags: `Slurm`, `HPC`, `Linux`, `Slinky`, `SlinkyProject`, `Partition`, `scontrol create partitionname`, `sacctmgr`, `scontrol`, `slurm.conf`, `AllowGroups`, `AllowAccounts`, `Hidden`, `PrivateData` <br> [TOC] <br> ## 如何套用設定? - 修改 `slurm.conf` -> `$ scontrol reconfigure` - `$ scontrol create/add ...` -> 立即生效 - `$ scontrol modify/updae ...` -> 立即生效 <br> ## 動態新增 partition ``` $ scontrol create \ partitionname=debug \ nodes=esc8000a-[0-1] \ Default=NO \ MaxTime=UNLIMITED \ State=UP $ scontrol show partitions PartitionName=tn AllowGroups=ALL AllowAccounts=ALL AllowQos=ALL AllocNodes=ALL Default=YES QoS=N/A DefaultTime=NONE DisableRootJobs=NO ExclusiveUser=NO ExclusiveTopo=NO GraceTime=0 Hidden=NO MaxNodes=UNLIMITED MaxTime=UNLIMITED MinNodes=0 LLN=NO MaxCPUsPerNode=UNLIMITED MaxCPUsPerSocket=UNLIMITED NodeSets=esc8000b Nodes=esc8000b-0 PriorityJobFactor=1 PriorityTier=1 RootOnly=NO ReqResv=NO OverSubscribe=NO OverTimeLimit=NONE PreemptMode=OFF State=UP TotalCPUs=80 TotalNodes=1 SelectTypeParameters=NONE JobDefaults=(null) DefMemPerNode=UNLIMITED MaxMemPerNode=UNLIMITED TRES=cpu=80,mem=240G,node=1,billing=80,gres/gpu=8 PartitionName=debug AllowGroups=ALL AllowAccounts=ALL AllowQos=ALL AllocNodes=ALL Default=NO QoS=N/A DefaultTime=NONE DisableRootJobs=NO ExclusiveUser=NO ExclusiveTopo=NO GraceTime=0 Hidden=NO MaxNodes=UNLIMITED MaxTime=UNLIMITED MinNodes=1 LLN=NO MaxCPUsPerNode=UNLIMITED MaxCPUsPerSocket=UNLIMITED Nodes=esc8000a-[0-1] PriorityJobFactor=1 PriorityTier=1 RootOnly=NO ReqResv=NO OverSubscribe=NO OverTimeLimit=NONE PreemptMode=OFF State=UP TotalCPUs=24 TotalNodes=2 SelectTypeParameters=NONE JobDefaults=(null) DefMemPerNode=UNLIMITED MaxMemPerNode=UNLIMITED TRES=cpu=22,mem=480G,node=2,billing=22,gres/gpu=2 $ srun -p debug hostname esc8000a-1 $ srun -p debug nvidia-smi -L GPU 0: NVIDIA A40 (UUID: GPU-35729da9-1b69-c8f6-9f22-************) GPU 1: NVIDIA A40 (UUID: GPU-157a6555-49d1-07bc-bf97-************) GPU 2: NVIDIA A40 (UUID: GPU-14c00e59-b533-e691-f568-************) GPU 3: NVIDIA A40 (UUID: GPU-228d9110-2bf1-6707-1afe-************) GPU 4: NVIDIA A40 (UUID: GPU-755ec026-8359-581c-b638-************) GPU 5: NVIDIA A40 (UUID: GPU-960a7fde-5e36-47d9-64e0-************) GPU 6: NVIDIA A40 (UUID: GPU-9c40d7e3-7322-d916-c6a9-************) GPU 7: NVIDIA A40 (UUID: GPU-b42813b5-fbfe-100d-d062-************) ``` <br> --- --- <br> ## `scontrol update partitionname=<name>` ``` # 1. 設定 partition 的預設記憶體限制 scontrol update partitionname=cpu-set defmempernode=1024 # 2. 調整節點的 MemSpec 限制(釋放更多可用記憶體) scontrol update nodename=c2m4-0 memspeclimit=0 # 3. 驗證配置 scontrol show partition cpu-set | grep DefMemPerNode scontrol show node c2m4-0 | grep MemSpec ``` <br> ## 常見操作 ### 解除 drain ```bash $ sinfo PARTITION AVAIL TIMELIMIT NODES STATE NODELIST cpu-set* up infinite 1 drain c2m4-0 $ scontrol update NodeName=c2m4-0 State=RESUME # 順便清掉原因 scontrol update NodeName=ocis-c8m16-0 State=RESUME Reason="" ``` - 不是解除 drain 的作法 ``` $ scontrol update PartitionName=cpu-set State=UP ``` - 建議先查 drain 原因(避免 RESUME 後又馬上被 drain) ```bash $ scontrol show node ocis-c8m16-0 # 或 $ sinfo -R ``` <br> --- --- <br> ## 討論 ### Partition / AllowGroups 設定限制分析 - ### Question ``` # slurm.conf PartitionName=debug Nodes=e900 Default=NO MaxTime=UNLIMITED State=UP AllowGroups=tj-group AllowAccounts=tj-account ``` 一個 partition 設置了 `AllowGroups=tj-group` - login, controller, compute 等相關節點,需要如何進行設定? - 對使用者來說有什麼限制? - ### gpt-5 (2025/08/29) 以下用你這段設定為例: ``` PartitionName=debug Nodes=e900 Default=NO MaxTime=UNLIMITED State=UP \ AllowGroups=tj-group AllowAccounts=tj-account ``` ### 叢集各節點需要怎麼設 * **slurm.conf 要一致**:`slurm.conf` 必須在 **controller、login、compute** 等所有節點完全一致(含這條 partition 設定)。改完在 controller 執行 `scontrol reconfigure` 套用即可,變更允許的帳號/群組**不用**重啟 slurmd。 ([Niflheim][1], [SchedMD][2]) * **建立/同步 UNIX 群組**:在你的**身分來源**(/etc/group、LDAP/SSSD、AD…)建好 `tj-group`,並把允許的使用者加進去。**重點**:`slurmctld`(controller)會根據本機可查到的群組成員快取來判斷是否允許,確保在 **controller** 上 `id <user>` 能看到 `tj-group`。群組成員名單的更新與快取由 `GroupUpdateTime/GroupUpdateForce` 控制。 ([Slurm][3], [Debian Manpages][4]) * **Slurm 帳號關聯**:因為有 `AllowAccounts=tj-account`,你還要在 Slurm DB 內把使用者關聯到 `tj-account`(`sacctmgr add/modify user ... account=tj-account`)。否則帳號不被允許。 ([Slurm][5], [JHPCE][6]) * **立即在提交時擋下(建議)**:在 `slurm.conf` 加上 `EnforcePartLimits=ALL`,不符 partition 限制(含 AllowGroups/AllowAccounts)的工作會在 **提交當下**被拒絕;若未啟用,工作只會排隊但無法被排程。 ([Slurm][3]) > 小提醒 > > * 若同時設定 `AllowAccounts` 與 `DenyAccounts`,前者會蓋過後者;partition 沒有 `DenyGroups` 選項。 ([Slurm][5], [Server Fault][7]) <br> ### 對使用者的具體限制與行為 * **門檻是 AND 條件**:要能在 `debug` 跑工作,使用者必須 **同時**屬於 UNIX 群組 `tj-group` **且** 其 Slurm 帳號屬於 `tj-account`;這兩者都是 partition limit,會被強制檢查。 ([Slurm][3]) * **提交指令範例**: * 若預設帳號不是 `tj-account`,需明確指定:`srun -p debug -A tj-account hostname`。不然可能見到 `Reason=AccountNotAllowed`。 ([Google Groups][8]) * 若不是 `tj-group` 成員,提交時會得到錯誤:`User's group not permitted to use this partition`。 ([Google Groups][9]) * **管理者例外**:具 Slurm Admin/Operator 權限的人在部分限制上可有管理性例外(例如修改工作屬性等)。 ([Slurm][10]) <br> ### 快速自檢清單 1. `scontrol show partition debug | egrep 'Allow|Nodes|State'`:確認 AllowAccounts/AllowGroups 生效。 ([Slurm][5]) 2. 在 **controller**:`id <user>` / `getent group tj-group`:確認群組成員同步無誤(等 `GroupUpdateTime` 或 `scontrol reconfigure` 後再試)。 ([Slurm][3]) 3. `sacctmgr list associations user=<user>`:確認使用者與 `tj-account` 的關聯存在。 ([JHPCE][6]) 4. `squeue -j <jobid> -o "%i %P %r"`:若被擋,從 Reason 診斷(如 `AccountNotAllowed` / group not permitted)。 ([Google Groups][8]) 這樣設定下來,就能以 **UNIX 群組**(`tj-group`)+ **Slurm 帳號**(`tj-account`)雙重條件,精準控管誰能用 `debug` 這個 partition。 [1]: https://niflheim-system.readthedocs.io/en/latest/Slurm_configuration.html?utm_source=chatgpt.com "Slurm configuration — Niflheim 24.07 documentation" [2]: https://bugs.schedmd.com/show_bug.cgi?id=6306&utm_source=chatgpt.com "6306 – Enabling new partition for all users" [3]: https://slurm.schedmd.com/slurm.conf.html?utm_source=chatgpt.com "Slurm Workload Manager - slurm.conf" [4]: https://manpages.debian.org/testing/slurm-client/slurm.conf.5.en.html?utm_source=chatgpt.com "slurm.conf(5) — slurm-client — Debian testing" [5]: https://slurm.schedmd.com/scontrol.html?utm_source=chatgpt.com "scontrol - Slurm Workload Manager" [6]: https://jhpce.jhu.edu/slurm/tips-sacctmgr/?utm_source=chatgpt.com "sacctmgr tips" [7]: https://serverfault.com/questions/617081/how-to-use-both-allowgroups-and-allowusers-in-sshd-config?utm_source=chatgpt.com "ssh - How to use both AllowGroups and AllowUsers in ..." [8]: https://groups.google.com/g/slurm-users/c/mJwvyZGFt4w?utm_source=chatgpt.com "[slurm-users] Problem with assigning user to partition" [9]: https://groups.google.com/g/slurm-users/c/RWsMyD21Xcc?utm_source=chatgpt.com "[slurm-users] AllowGroups for Partition not working?" [10]: https://slurm.schedmd.com/user_permissions.html?utm_source=chatgpt.com "User Permissions - Slurm Workload Manager - SchedMD" <br> --- - ### DeepWiki (2025/08/29) > https://deepwiki.com/search/-slurmconf-partitionnamedebug_93d101fc-912c-4a61-8b2f-c62b28853a9a > 根據您的問題,我來詳細說明 SLURM 中 partition 設置 `AllowGroups=tj-group` 的相關設定和限制: ### 節點設定要求 **所有節點都需要相同的配置文件:** 所有的 login、controller、compute 節點都必須使用相同的 `slurm.conf` 配置文件。 [1](#0-0) **各類型節點的服務配置:** - Controller 節點:需要啟用 `slurmctld` 服務 - Compute 節點:需要啟用 `slurmd` 服務 - Login 節點:通常只需要安裝 Slurm 客戶端工具 [2](#0-1) ### AllowGroups 參數功能 `AllowGroups` 參數用於識別哪些使用者群組可以使用該 partition。可以指定多個群組,使用逗號分隔的列表。如果要允許所有群組使用該 partition,需要指定 "AllowGroups=ALL"。 [3](#0-2) ### 對使用者的限制 **群組成員資格檢查:** 當 partition 設置了 `AllowGroups=tj-group` 時,系統會執行以下檢查: 1. 如果 `allow_groups` 為 NULL,則所有使用者都被允許 2. 如果使用者是 Slurm 超級使用者,則允許在任何地方執行 3. 系統會檢查使用者是否在允許的群組列表中 [4](#0-3) **實際限制效果:** - 只有屬於 `tj-group` 的使用者才能向該 partition 提交作業 - 不屬於該群組的使用者嘗試提交作業時會被拒絕 - 系統會快取失敗的權限檢查結果 5 秒鐘以提高效能 [5](#0-4) **群組驗證機制:** 系統會解析 `allow_groups` 中的群組名稱(以逗號分隔),並檢查使用者的主要群組是否在允許的群組列表中。 [6](#0-5) ### Notes - 所有節點必須同步使用者和群組資訊(UIDs 和 GIDs)以確保權限檢查正確運作 - 如果使用大型的使用者/群組資料庫,建議停用使用者/群組枚舉功能以避免對目錄服務器造成負載 - 權限檢查會在作業提交時進行,而不是在節點執行時才檢查 - 此設定與 `AllowAccounts`(Slurm 帳戶實體)不同,`AllowGroups` 是針對 UNIX 系統群組的限制 <br> --- - ### mycoder_bot / Claude 3.7 Sonnet (2025/08/29) 根據研究,我整理出關於 Slurm `AllowGroups` 設定的資訊: ### 節點設定要求 1. **控制節點 (Controller Node):** - 需在 `slurm.conf` 中設定分區的 AllowGroups - 需有存取群組資料庫的權限(LDAP、本地檔案等) - 可配置 `GroupUpdateTime` 參數控制群組資訊更新頻率 2. **計算節點 (Compute Node):** - 需與控制節點同步相同的 `slurm.conf` 配置 - 需有同步的使用者/群組資料庫 - 不需特別針對 AllowGroups 進行額外設定 3. **登入節點 (Login Node):** - 需有對 `slurm.conf` 的唯讀存取權 - 不需額外設定,僅使用客戶端命令 ### 使用者限制 1. **作業提交限制:** - 不屬於指定群組的使用者無法提交作業到該分區 - 提交失敗時會顯示錯誤:「User's group not permitted to use this partition」 2. **可見性限制:** - 預設情況下,未授權使用者看不到設有 AllowGroups 限制的分區 - 在 `sinfo` 輸出中不會顯示這些分區 - 此機制非完全安全性措施,若使用者知道分區名稱仍可查詢特定資訊 3. **特殊使用者例外:** - Root 使用者:不受 AllowGroups 限制 - SlurmUser:不受 AllowGroups 限制 - Slurm 管理員/操作員:可查看任何分區資訊 4. **與 AllowAccounts 的關係:** - 兩種限制獨立執行 - 使用者必須同時滿足 AllowGroups 和 AllowAccounts 的要求 - 若設置 AllowAccounts,則 DenyAccounts 設定會被忽略 以您提供的設定為例: ``` PartitionName=debug Nodes=e900 Default=NO MaxTime=UNLIMITED State=UP AllowGroups=tj-group AllowAccounts=tj-account ``` 這表示只有屬於 `tj-group` 群組且使用 `tj-account` 帳戶的使用者才能提交作業到 debug 分區。 <br> --- ### 在建立完 slurm cluster 後,是否能能動態新增 partition? - ### gpt-5 (2025/09/08) 可以!而且不需要重建整個叢集。 下面給你兩條路:**立即生效(臨時)** 與 **永久生效(建議)**。兩者都不會中斷現有工作。 --- ### A) 立即生效:用 `scontrol` 動態新增/調整 Partition > 適合先測,之後再把設定寫回 `slurm.conf`。 ```bash # 1) 在 slurmctld 節點/Pod 內執行(或能連到 slurmctld 的主機) scontrol create PartitionName=tn Nodes=e900[1-2] Default=NO MaxTime=UNLIMITED State=UP # 2) 檢查 scontrol show partition tn sinfo -p tn # 3)(可選)限制可用帳號/群組 scontrol update PartitionName=tn AllowAccounts=tn # 或 scontrol update PartitionName=tn AllowGroups=tn-group ``` **注意** * `scontrol create/update` 屬於**即時配置**,重讀 `slurm.conf`(或 slurmctld 重啟)時可能被覆蓋。所以確認可用後,請做 B 流程把設定寫回檔案。 * 變更節點清單時,`Nodes=...` 會以你提供的清單為準,等同覆寫;請給完整清單。 --- ### B) 永久生效(建議):修改 `slurm.conf` + `reconfigure` > 在 K8s(Slinky/Helm)通常是改 ConfigMap 或 Helm values 中的 `slurm.conf` 片段,然後重載。 1. 在 `slurm.conf` 增加(或調整)一行: ```conf PartitionName=tn Nodes=e900[1-2] Default=NO MaxTime=UNLIMITED State=UP AllowAccounts=tn ``` 2. 套用後**重載**(不會中斷現有工作): ```bash # 進入 slurmctld Pod kubectl -n slurm exec -it <slurmctld-pod> -- scontrol reconfigure # 檢查 kubectl -n slurm exec -it <slurmctld-pod> -- scontrol show partition tn ``` > 如果你用 Helm 管理,更新 values 後 `helm upgrade`,控制器起來後再 `scontrol reconfigure` 即可。 --- ### (若啟用會計/關聯)把人/帳號綁到新 Partition 你的環境若設定 `AccountingStorageEnforce=associations`(常見),需要建立關聯,否則使用者會無法送到新 partition: ```bash # 建 account(若尚未) sacctmgr create account name=tn # 建使用者並綁定 account(舉例) sacctmgr create user name=alice account=tn # 建立 partition 關聯(很重要) sacctmgr create assoc account=tn cluster=slurm partition=tn #(可選)把預設帳號設為 tn sacctmgr modify user name=alice set DefaultAccount=tn # 驗證 sacctmgr list assoc where account=tn ``` --- ### 測試 ```bash sinfo -p tn srun -p tn -A tn -N1 -n1 hostname ``` --- ### 下架/移除 * 臨時下架:`scontrol update PartitionName=tn State=DOWN` 或 `Hidden=YES` * 永久移除:從 `slurm.conf` 刪除該行後 `scontrol reconfigure`(必要時先確保沒有作業在該 partition) --- ### 常見坑位 * **節點名稱對不上**:`Nodes=` 必須匹配 `slurmd` 的 `NodeName`/HostName(用 `scontrol show nodes` 看實名)。 * **忘了關聯**:啟用 association 強制時,沒建 `assoc` 會報提交錯誤。 * **被覆蓋**:用 `scontrol` 測完卻沒寫回 `slurm.conf`,下一次 reconfigure/重啟就失效。 需要我根據你目前的節點命名(例如 `e900[1-4]`、`a40[1-2]`)幫你寫一條精準的 `PartitionName=` 行嗎?我也可以順手給你對應的 `sacctmgr` 指令組合。 <br> {%hackmd vaaMgNRPS4KGJDSFG0ZE0w %}

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password
    or
    Sign in via Facebook Sign in via X(Twitter) Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    By signing in, you agree to our terms of service.

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully