TWI409700B - Device and method for notifying configuration files change in multiple operation systems - Google Patents
Device and method for notifying configuration files change in multiple operation systems Download PDFInfo
- Publication number
- TWI409700B TWI409700B TW99126693A TW99126693A TWI409700B TW I409700 B TWI409700 B TW I409700B TW 99126693 A TW99126693 A TW 99126693A TW 99126693 A TW99126693 A TW 99126693A TW I409700 B TWI409700 B TW I409700B
- Authority
- TW
- Taiwan
- Prior art keywords
- operating system
- device configuration
- configuration file
- message
- changed
- Prior art date
Links
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Information Transfer Between Computers (AREA)
Abstract
Description
本發明涉及一種消息通知系統及方法,尤其係關於一種在多個作業系統中變更設備配置檔案之消息通知裝置及方法。The present invention relates to a message notification system and method, and more particularly to a message notification apparatus and method for changing a device configuration file in a plurality of operating systems.
隨著電腦技術的不斷發展,越來越多的電腦系統(例如潛入式系統)採用多個作業系統,例如Linux作業系統。然而,在現有的多作業系統架構下,每一個作業系統都需要配置各自的系統資源,例如設備配置檔案需要保存在每一個作業系統對應的儲存單元。以雙作業系統為例,相同的設備配置檔案不僅需要在第一作業系統的儲存單元儲存一份,而且也需要在第二作業系統的儲存單元儲存一份,這種相同檔案需要保存兩份的儲存機制浪費了儲存空間。此外,當設備配置檔案發生變化時,第一作業系統與第二作業系統需要同步地進行備份變更的設備配置檔案,操作起來比較繁瑣,並且佔用系統資源,降低了系統的執行效率。With the continuous development of computer technology, more and more computer systems (such as submersible systems) use multiple operating systems, such as Linux operating systems. However, under the existing multi-operation system architecture, each operating system needs to be configured with its own system resources. For example, the device configuration file needs to be stored in the storage unit corresponding to each operating system. In the case of a dual operating system, the same device configuration file not only needs to be stored in the storage unit of the first operating system, but also needs to be stored in the storage unit of the second operating system. This same file needs to be saved in two copies. The storage mechanism wastes storage space. In addition, when the device configuration file changes, the first operating system and the second operating system need to perform backup and change device configuration files in synchronization, which is cumbersome to operate, and occupies system resources, thereby reducing system execution efficiency.
鑒於以上內容,有必要提供一種變更設備配置檔案之消息通知裝置及方法,能夠使多個作業系統共用相同的設備配置資訊,並且即時監控共用的設備配置資訊的變化情況,從而節省儲存空間及提高系統效率。In view of the above, it is necessary to provide a message notification device and method for changing a device configuration file, which enables multiple operating systems to share the same device configuration information and instantly monitor changes in shared device configuration information, thereby saving storage space and improving System efficiency.
所述之變更設備配置檔案之消息通知裝置,該裝置包括第一作業系統及第二作業系統。該第二作業系統藉由網路檔案系統共用第一作業系統的設備配置檔案,該第一作業系統包括:內核監控模組,用於即時監控第一作業系統中的設備配置檔案是否被變更,當設備配置檔案被變更時,產生事件通知消息並將該事件通知消息告知第一應用程式所述之設備配置檔案已變更;及消息發送模組,用於將該事件通知消息發送至第二作業系統。所述之第二作業系統包括消息接收模組,用於接收消息發送模組發送的事件通知消息,並根據該事件通知消息告知第二應用程式所述之設備配置檔案已變更。The message notification device for changing a device configuration file, the device comprising a first operating system and a second operating system. The second operating system shares the device configuration file of the first operating system by the network file system, and the first operating system includes: a kernel monitoring module, configured to immediately monitor whether the device configuration file in the first operating system is changed, When the device configuration file is changed, generating an event notification message and notifying the event notification message that the device configuration file is changed by the first application; and a message sending module, configured to send the event notification message to the second job system. The second operating system includes a message receiving module, configured to receive an event notification message sent by the message sending module, and notify the second application that the device configuration file has been changed according to the event notification message.
所述之變更設備配置檔案之消息通知方法,該方法包括步驟:初始化第一作業系統及第二作業系統,該第二作業系統藉由網路檔案系統共用第一作業系統的設備配置檔案;即時監控第一作業系統中的設備配置檔案是否被變更;當設備配置檔案被變更時,產生事件通知消息並將該事件通知消息告知第一作業系統的第一應用程式所述之設備配置檔案已變更;將事件通知消息發送至第二作業系統;第二作業系統接收該事件通知消息,並根據該事件通知消息告知第二作業系統的第二應用程式所述之設備配置檔案已變更。The message notification method for changing a device configuration file, the method comprising the steps of: initializing a first operating system and a second operating system, wherein the second operating system shares a device configuration file of the first operating system by using a network file system; Monitoring whether the device configuration file in the first operating system is changed; when the device configuration file is changed, generating an event notification message and notifying the event notification message that the device configuration file described by the first application of the first operating system has been changed Sending an event notification message to the second operating system; the second operating system receives the event notification message, and according to the event notification message, notifying that the device configuration file described by the second application of the second operating system has been changed.
相較於習知技術,本發明所述之變更設備配置檔案之消息通知裝置及方法,能夠使多個作業系統共用相同的設備配置資訊,並且即時地監控多個作業系統中的設備配置資訊是否發生變更,當某一個作業系統中的配置檔案發生變化時,藉由消息通知機制通知每一個作業系統共用變更的設備配置資訊。Compared with the prior art, the message notification device and method for changing the device configuration file according to the present invention can enable multiple operating systems to share the same device configuration information, and monitor device configuration information in multiple operating systems in real time. A change occurs, and when the configuration file in a certain operating system changes, the message notification mechanism notifies each operating system to share the changed device configuration information.
如圖1所示,係為本發明變更設備配置檔案之消息通知裝置100較佳實施例的實施架構圖。所述之消息通知裝置100安裝有多個作業系統,該作業系統為Windows作業系統、或Linux作業系統。本實施例中,該消息通知裝置100包括第一作業系統1及第二作業系統2。該第一作業系統1被第一中央處理器(Central processing unit,CPU)15執行,該第二作業系統2被第二中央處理器23執行。所述之第一作業系統1包括第一設備管理程式10、設備配置檔案11、內核監控模組12、第一應用程式13及消息發送模組14。所述之第二作業系統2包括第二設備管理程式20、第二應用程式21及消息接收模組22。As shown in FIG. 1, it is an implementation architecture diagram of a preferred embodiment of the message notification apparatus 100 for changing a device configuration file of the present invention. The message notification device 100 is installed with a plurality of operating systems, which are Windows operating systems or Linux operating systems. In the embodiment, the message notification device 100 includes a first operating system 1 and a second operating system 2. The first operating system 1 is executed by a first central processing unit (CPU) 15, which is executed by a second central processing unit 23. The first operating system 1 includes a first device management program 10, a device configuration file 11, a kernel monitoring module 12, a first application program 13, and a message sending module 14. The second operating system 2 includes a second device management program 20, a second application program 21, and a message receiving module 22.
所述之第二作業系統2藉由網路檔案系統(Network file system,NFS)共用儲存在記憶體16中的設備配置檔案11。該設備配置檔案11記錄有各種設備的配置資訊,例如CPU配置資訊、外圍設備配置資訊及I/O埠配置資訊等。第一設備管理程式10或第二設備管理程式20為用戶變更設備資訊時提供用戶介面,當用戶藉由第一設備管理程式10或第二設備管理程式20變更設備配置資訊時,設備配置檔案11記錄相應的設備變更資訊。The second operating system 2 shares the device configuration file 11 stored in the memory 16 by a network file system (NFS). The device configuration file 11 records configuration information of various devices, such as CPU configuration information, peripheral device configuration information, and I/O configuration information. The first device management program 10 or the second device management program 20 provides a user interface when the user changes the device information. When the user changes the device configuration information by using the first device management program 10 or the second device management program 20, the device configuration file 11 Record the corresponding device change information.
所述之內核監控模組12用於即時地監控第一作業系統1中的設備配置檔案11,及判斷設備配置檔案11是否被第一設備管理程式或第二設備管理程式變更。當設備配置檔案11被變更時,內核監控模組12產生事件通知消息並將該事件通知消息告知第一應用程式13所述之設備配置檔案11已變更,及將該事件通知消息發送給消息發送模組14。當第一應用程式13接收到該事件通知消息後,藉由內核監控模組12直接獲取設備配置檔案11的變更內容。The kernel monitoring module 12 is configured to monitor the device configuration file 11 in the first operating system 1 in real time, and determine whether the device configuration file 11 is changed by the first device management program or the second device management program. When the device configuration file 11 is changed, the kernel monitoring module 12 generates an event notification message and notifies the event notification message that the device configuration file 11 described by the first application 13 has been changed, and sends the event notification message to the message. Module 14. After the first application 13 receives the event notification message, the kernel monitoring module 12 directly obtains the changed content of the device configuration file 11.
所述之消息發送模組14用於將接收到的事件通知消息發送至第二作業系統2。所述之消息接收模組22用於接收消息發送模組14發送的事件通知消息,並根據該事件通知消息告知第二應用程式21所述之設備配置檔案11已變更。當第二應用程式21接收到該事件通知消息後,藉由NFS共用第一作業系統1中設備配置檔案11的變更內容。The message sending module 14 is configured to send the received event notification message to the second operating system 2. The message receiving module 22 is configured to receive an event notification message sent by the message sending module 14, and notify the second application 21 that the device configuration file 11 has been changed according to the event notification message. When the second application 21 receives the event notification message, the changed content of the device configuration file 11 in the first operating system 1 is shared by NFS.
如圖2所示,係為本發明變更設備配置檔案之消息通知方法較佳實施例的流程圖。在本實施例中,該方法能夠即時地監控多個作業系統中的設備配置資訊是否發生變更,當某一個作業系統中的配置檔案發生變化時,藉由消息通知機制通知每一個作業系統共用變更的設備配置資訊。本實施例僅以兩個作業系統為例來闡述本發明,即圖1所示的第一作業系統1及第二作業系統2。As shown in FIG. 2, it is a flowchart of a preferred embodiment of a message notification method for changing a device configuration file according to the present invention. In this embodiment, the method can instantly monitor whether the device configuration information in the plurality of operating systems changes. When the configuration file in a certain operating system changes, the notification mechanism notifies each operating system to share the change. Device configuration information. This embodiment illustrates the present invention by taking only two operating systems as an example, namely the first operating system 1 and the second operating system 2 shown in FIG.
步驟S21,第一中央處理器15初始化第一作業系統1,及第二中央處理器23初始化第二作業系統2。該第二作業系統2藉由網路檔案系統(NFS)共用第一作業系統1中的設備配置檔案11。該設備配置檔案11記錄有各種設備的配置資訊,例如CPU配置資訊、外圍設備配置資訊及I/O埠配置資訊等。當用戶藉由第一設備管理程式10或第二設備管理程式20變更設備配置資訊時,所述之設備配置檔案11記錄相應的設備變更資訊。In step S21, the first central processing unit 15 initializes the first operating system 1, and the second central processing unit 23 initializes the second operating system 2. The second operating system 2 shares the device configuration file 11 in the first operating system 1 by a network file system (NFS). The device configuration file 11 records configuration information of various devices, such as CPU configuration information, peripheral device configuration information, and I/O configuration information. When the user changes the device configuration information by the first device management program 10 or the second device management program 20, the device configuration file 11 records the corresponding device change information.
步驟S22,內核監控模組12即時地監控第一作業系統1中的設備配置檔案11。步驟S23,內核監控模組12檢查設備配置檔案11是否被第一設備管理程式10變更。若設備配置檔案11沒有被第一設備管理程式10變更,則執行步驟S24。若設備配置檔案11已被第一設備管理程式10變更,則執行步驟S25。In step S22, the kernel monitoring module 12 instantly monitors the device configuration file 11 in the first operating system 1. In step S23, the kernel monitoring module 12 checks whether the device configuration file 11 is changed by the first device management program 10. If the device configuration file 11 is not changed by the first device management program 10, step S24 is performed. If the device configuration file 11 has been changed by the first device management program 10, step S25 is performed.
步驟S24,內核監控模組12檢查設備配置檔案11是否被第二設備管理程式20變更。若設備配置檔案沒有被第二設備管理程式20變更,則返回步驟S22,即內核監控模組12繼續監控第一作業系統1中的設備配置檔案11是否被變更。若設備配置檔案已被第二設備管理程式20變更,則執行步驟S25。In step S24, the kernel monitoring module 12 checks whether the device configuration file 11 is changed by the second device management program 20. If the device configuration file has not been changed by the second device management program 20, the process returns to step S22, that is, the kernel monitoring module 12 continues to monitor whether the device configuration file 11 in the first operating system 1 has been changed. If the device configuration file has been changed by the second device management program 20, step S25 is performed.
步驟S25,內核監控模組12產生事件通知消息並將該事件通知消息通知第一應用程式13所述之設備配置檔案11已變更。當第一應用程式13接收到該事件通知消息後,藉由內核監控模組12直接獲取設備配置檔案11的變更內容。In step S25, the kernel monitoring module 12 generates an event notification message and notifies the event notification message that the device configuration file 11 described by the first application 13 has been changed. After the first application 13 receives the event notification message, the kernel monitoring module 12 directly obtains the changed content of the device configuration file 11.
步驟S26,內核監控模組12將該事件通知消息發送給消息發送模組14,消息發送模組14將接收到的事件通知消息發送至第二作業系統2。In step S26, the kernel monitoring module 12 sends the event notification message to the message sending module 14, and the message sending module 14 sends the received event notification message to the second operating system 2.
步驟S27,第二作業系統2的消息接收模組22接收消息發送模組14發送的事件通知消息,並根據該事件通知消息告知第二應用程式21設備配置檔案11已變更。當第二應用程式21接收到該事件通知消息後,藉由網路檔案系統(NFS)共用第一作業系統1中設備配置檔案11的變更內容。In step S27, the message receiving module 22 of the second operating system 2 receives the event notification message sent by the message sending module 14, and informs the second application 21 that the device configuration file 11 has been changed according to the event notification message. After the second application 21 receives the event notification message, the change content of the device configuration file 11 in the first operating system 1 is shared by the network file system (NFS).
以上所述僅為本發明之較佳實施例而已,且已達廣泛之使用功效,凡其他未脫離本發明所揭示之精神下所完成之均等變化或修飾,均應包含於下述之申請專利範圍內。The above is only the preferred embodiment of the present invention, and has been used in a wide range of applications. Any other equivalent changes or modifications that are not departing from the spirit of the present invention should be included in the following patent application. Within the scope.
100‧‧‧消息通知裝置100‧‧‧ message notification device
1‧‧‧第一作業系統1‧‧‧First operating system
10‧‧‧第一設備管理程式10‧‧‧First Device Manager
11‧‧‧設備配置檔案11‧‧‧Device configuration file
12‧‧‧內核監控模組12‧‧‧ Kernel Monitoring Module
13‧‧‧第一應用程式13‧‧‧First application
14‧‧‧消息發送模組14‧‧‧Message Sending Module
15‧‧‧第一CPU15‧‧‧First CPU
16‧‧‧記憶體16‧‧‧ memory
2‧‧‧第二作業系統2‧‧‧Second operating system
20‧‧‧第二設備管理程式20‧‧‧Second Device Manager
21‧‧‧第二應用程式21‧‧‧Second application
22‧‧‧消息接收模組22‧‧‧Message receiving module
23‧‧‧第二CPU23‧‧‧Second CPU
圖1係為本發明變更設備配置檔案之消息通知裝置較佳實施例的實施架構圖。FIG. 1 is a schematic structural diagram of a preferred embodiment of a message notification apparatus for changing a device configuration file according to the present invention.
圖2係為本發明變更設備配置檔案之消息通知方法較佳實施例的流程圖。2 is a flow chart of a preferred embodiment of a message notification method for changing a device configuration file according to the present invention.
100‧‧‧消息通知裝置 100‧‧‧ message notification device
1‧‧‧第一作業系統 1‧‧‧First operating system
10‧‧‧第一設備管理程式 10‧‧‧First Device Manager
11‧‧‧設備配置檔案 11‧‧‧Device configuration file
12‧‧‧內核監控模組 12‧‧‧ Kernel Monitoring Module
13‧‧‧第一應用程式 13‧‧‧First application
14‧‧‧消息發送模組 14‧‧‧Message Sending Module
15‧‧‧第一CPU 15‧‧‧First CPU
16‧‧‧記憶體 16‧‧‧ memory
2‧‧‧第二作業系統 2‧‧‧Second operating system
20‧‧‧第二設備管理程式 20‧‧‧Second Device Manager
21‧‧‧第二應用程式 21‧‧‧Second application
22‧‧‧消息接收模組 22‧‧‧Message receiving module
23‧‧‧第二CPU 23‧‧‧Second CPU
Claims (10)
所述之第二作業系統藉由網路檔案系統共用第一作業系統的設備配置檔案,該第一作業系統包括:
內核監控模組,用於即時監控第一作業系統中的設備配置檔案是否被變更,當設備配置檔案被變更時,產生事件通知消息並將該事件通知消息告知第一應用程式所述之設備配置檔案已變更;及
消息發送模組,用於將該事件通知消息發送至第二作業系統;
該第二作業系統包括消息接收模組,用於接收消息發送模組發送的事件通知消息,並根據該事件通知消息告知第二應用程式所述之設備配置檔案已變更。A message notification device for changing a device configuration file, comprising a first operating system and a second operating system, wherein:
The second operating system shares the device configuration file of the first operating system by the network file system, and the first operating system includes:
The kernel monitoring module is configured to monitor whether the device configuration file in the first operating system is changed, and when the device configuration file is changed, generate an event notification message and notify the event notification message to the device configuration described by the first application. The file has been changed; and a message sending module is configured to send the event notification message to the second operating system;
The second operating system includes a message receiving module, configured to receive an event notification message sent by the message sending module, and notify the second application that the device configuration file has been changed according to the event notification message.
判斷設備配置檔案是否被第一作業系統的第一設備管理程式變更;及
判斷設備配置檔案是否被第二作業系統的第二設備管理程式變更。The message notification device of claim 1, wherein the kernel monitoring module immediately monitors whether the device configuration file in the first operating system is changed comprises:
Determining whether the device configuration file is changed by the first device management program of the first operating system; and determining whether the device configuration file is changed by the second device management program of the second operating system.
初始化第一作業系統及第二作業系統,該第二作業系統藉由網路檔案系統共用第一作業系統的設備配置檔案;
即時監控第一作業系統中的設備配置檔案是否被變更;
當設備配置檔案被變更時,產生事件通知消息並將該事件通知消息告知第一應用程式所述之設備配置檔案已變更;
將事件通知消息發送至第二作業系統;及
第二作業系統接收該事件通知消息,並根據該事件通知消息告知第二應用程式所述之設備配置檔案已變更。A message notification method for changing a device configuration file, the method comprising the steps of:
Initializing the first operating system and the second operating system, the second operating system sharing the device configuration file of the first operating system by the network file system;
Instantly monitor whether the device configuration file in the first operating system is changed;
When the device configuration file is changed, generating an event notification message and notifying the event notification message that the device configuration file described by the first application has been changed;
Sending an event notification message to the second operating system; and the second operating system receives the event notification message and notifying the second application that the device configuration file has been changed according to the event notification message.
判斷設備配置檔案是否被第一作業系統的第一設備管理程式變更;及
判斷設備配置檔案是否被第二作業系統的第二設備管理程式變更。The message notification method of claim 6, wherein the step of immediately monitoring whether the device configuration file in the first operating system is changed comprises:
Determining whether the device configuration file is changed by the first device management program of the first operating system; and determining whether the device configuration file is changed by the second device management program of the second operating system.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
TW99126693A TWI409700B (en) | 2010-08-11 | 2010-08-11 | Device and method for notifying configuration files change in multiple operation systems |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
TW99126693A TWI409700B (en) | 2010-08-11 | 2010-08-11 | Device and method for notifying configuration files change in multiple operation systems |
Publications (2)
Publication Number | Publication Date |
---|---|
TW201207733A TW201207733A (en) | 2012-02-16 |
TWI409700B true TWI409700B (en) | 2013-09-21 |
Family
ID=46762298
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
TW99126693A TWI409700B (en) | 2010-08-11 | 2010-08-11 | Device and method for notifying configuration files change in multiple operation systems |
Country Status (1)
Country | Link |
---|---|
TW (1) | TWI409700B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
TWI516059B (en) | 2013-05-09 | 2016-01-01 | 緯創資通股份有限公司 | Setup method and system for client and server environment |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050091349A1 (en) * | 2003-07-31 | 2005-04-28 | Daniel Scheibli | Automatically configuring a computer |
TW200736934A (en) * | 2006-03-24 | 2007-10-01 | Inventec Corp | System and method of accomplishing computer apparatus sharing |
-
2010
- 2010-08-11 TW TW99126693A patent/TWI409700B/en not_active IP Right Cessation
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050091349A1 (en) * | 2003-07-31 | 2005-04-28 | Daniel Scheibli | Automatically configuring a computer |
TW200736934A (en) * | 2006-03-24 | 2007-10-01 | Inventec Corp | System and method of accomplishing computer apparatus sharing |
Also Published As
Publication number | Publication date |
---|---|
TW201207733A (en) | 2012-02-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11681566B2 (en) | Load balancing and fault tolerant service in a distributed data system | |
JP6238309B2 (en) | Method for generating a snapshot of a shared volume with consistency between applications | |
US10831399B2 (en) | Method and system for enabling agentless backup and restore operations on a container orchestration platform | |
US10152246B1 (en) | Application aware AMQP durable messages backup and restore | |
CN102346725B (en) | Message notification device and method for changing equipment configuration file | |
US9558076B2 (en) | Methods and systems of cloud-based disaster recovery | |
US9912474B2 (en) | Performing telemetry, data gathering, and failure isolation using non-volatile memory | |
US9940283B2 (en) | Application sharing in multi host computing systems | |
TWI476692B (en) | Device and method for notifying configuration files change in multiple operation systems | |
WO2015081470A1 (en) | Data processing device and data processing method | |
US10216601B2 (en) | Agent dynamic service | |
CN105812169B (en) | A kind of switch between master and slave machines method and device | |
JP2021524104A (en) | Master / Standby Container System Switching | |
US10938957B1 (en) | System and method for bridging gaps between traditional resource management solutions with cloud-based management solutions | |
US9678838B2 (en) | Protecting virtual machines from network failures | |
JP6256931B2 (en) | Using cache and non-cache in distributed storage systems | |
WO2015078215A1 (en) | Device resource control method and apparatus | |
WO2013075501A1 (en) | Method and device for hot-plugging a node | |
US9591060B1 (en) | Transferring applications between computer systems | |
TWI409700B (en) | Device and method for notifying configuration files change in multiple operation systems | |
WO2017000589A1 (en) | Flexible capacity expansion method, apparatus and system | |
JP2007265137A (en) | Multi-task processing method and multi-task processing apparatus | |
US11442793B1 (en) | Fully dynamic virtual proxies for data protection | |
CN114064194A (en) | Resource processing method and device | |
US20200117522A1 (en) | Lightweight application programming interface (api) creation and management |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
MM4A | Annulment or lapse of patent due to non-payment of fees |